Problem/Motivation

Code sniffer for PHP 7.4 reports one warning:

-------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
-------------------------------------------------------------------------------------------------
 167 | WARNING | Passing the $glue and $pieces parameters in reverse order to implode has been
     |         | deprecated since PHP 7.4; $glue should be the first parameter and $pieces the
     |         | second
-------------------------------------------------------------------------------------------------

Steps to reproduce

Run phpcs with the PHP compatibility set to version 7.4

Proposed resolution

Switch the order of the arguments to implode()

Remaining tasks

Code review

User interface changes

None

API changes

None

Data model changes

None

Comments

cboyden created an issue. See original summary.

cboyden’s picture

Assigned: cboyden » Unassigned
Issue summary: View changes
Status: Active » Needs review
StatusFileSize
new580 bytes

Patch is attached.

mohangathala’s picture

Status: Needs review » Reviewed & tested by the community

Patch #2 works for me.

rajatc’s picture

Patch #2 works to me for PHP 7.4 warning.