When ran phpcs command to check PHP 7.2 compatibility got the following error.

FILE: ...ules/contrib/rules_conditional/includes/rules_conditional.ui.inc
----------------------------------------------------------------------
FOUND 20 ERRORS AFFECTING 17 LINES
----------------------------------------------------------------------
69 | ERROR | "$this" can no longer be used in a plain function or
| | method since PHP 7.1.
72 | ERROR | "$this" can no longer be used in a plain function or
| | method since PHP 7.1.
72 | ERROR | "$this" can no longer be used in a plain function or
| | method since PHP 7.1.

Comments

meet_bhanvadia created an issue. See original summary.

meet_bhanvadia’s picture

Fixing PHP compatibility issues for rules_conditional.

meet_bhanvadia’s picture

Status: Needs work » Needs review
meet_bhanvadia’s picture

Please do not use patch applied on comment 2. It is not resolving the PHP issue.

tr’s picture

Status: Needs review » Closed (duplicate)

There's already an issue open for this - please participate in that issue. #3065157: "$this" can no longer be used in a plain function or method since PHP 7.1.

liam morland’s picture

Issue tags: -PHP 7.2 compatibility +PHP 7.2