Plugin/Field/FieldType/PaymentMethod/generateSampleValue is static, but uses $this

Created on 13 June 2024, 5 months ago
Updated 29 June 2024, 5 months ago

Problem/Motivation

I edit my sites in VSCode, and recently noticed it pop up an error on the generateSampleValue function in Plugin/Field/FieldType/PaymentMethod.php. This is defined as a static method, but uses $this. $this is not available in a static method.

Steps to reproduce

View Paymentmethod.php in an editor that does code validation.

Proposed resolution

Either change generateSampleValue to a normal method, or change the code to work as a static method.

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Fixed

Version

2.0

Component

Code

Created by

🇺🇸United States Ben Coleman

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024