After running phpcs to the latest version getting the below php7 compatibility issues

FILE: sites/all/modules/contrib/apachesolr_multilingual/apachesolr_multilingual.index.inc
-------------------------------------------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 4 WARNINGS AFFECTING 4 LINES
-------------------------------------------------------------------------------------------------------------------------------------------------
24 | WARNING | Function each() is deprecated since PHP 7.2; Use a foreach loop instead
90 | WARNING | Function each() is deprecated since PHP 7.2; Use a foreach loop instead
147 | WARNING | Function each() is deprecated since PHP 7.2; Use a foreach loop instead
296 | WARNING | Function each() is deprecated since PHP 7.2; Use a foreach loop instead
-------------------------------------------------------------------------------------------------------------------------------------------------

Comments

gaurav.goyal created an issue. See original summary.

gaurav.goyal’s picture

StatusFileSize
new1.79 KB
gaurav.goyal’s picture

Status: Active » Needs review

Status: Needs review » Needs work

The last submitted patch, 2: apachesolr_multilingual-2998996.patch, failed testing. View results

tarik.cipix’s picture

Status: Needs work » Reviewed & tested by the community

I have started another automated test for PHP 7.2 and tested the patch myself. Seems to be working, please include in next release.

tarik.cipix’s picture

Status: Reviewed & tested by the community » Needs review
StatusFileSize
new1.38 KB

I have included another patch, the one in #2 isn't applying because the path is not relative. Please review.

tarik.cipix’s picture

StatusFileSize
new1.24 KB

I have included another patch, but I can't seem to get them to apply. Perhaps it needs to be a diff ?

rudolfbyker’s picture

Let's try without the long file paths in the patch :) I also took the liberty of removing unused variables.

rudolfbyker’s picture

Sorry, the patch needs to be p1, not p0. Silly me. See https://www.drupal.org/node/707484

julien.reulos’s picture

Status: Needs review » Reviewed & tested by the community

Last patch applies correctly and fixes the issue, thanks.

ruyakhokhar’s picture

Assigned: Unassigned » ruyakhokhar
Issue tags: +PHP 7.3
StatusFileSize
new51.72 KB

Hi all, patch#9 is working fine. Screenshot attached.

ruyakhokhar’s picture

Assigned: ruyakhokhar » Unassigned
vuil’s picture

Component: Code » Miscellaneous
Category: Support request » Task

The patch #9 works fine! It is ready to be committed. Thank you.