• As usual Wordfence does a great job, but I have a small issue that I cannot explain.

    I have several plugins on various sites that have plugins that do not have support, or the author does not respond even after waiting for many weeks. I have issues with deprecated code, when I change the server PHP version. To keep using them I make changes to the lines with the deprecated code. As with the lax authors, who do not update their versions properly, I get warnings from Wordfence about the modified files.

    I recently had warnings create_function() deprecated in PHP 7.2 use anonymous function in a plugin. I changed the affected code on two different lines in the PHP file and the plugin continued to work properly, but without any warnings.

    To my surprise, unlike with other similar code changes and even with high sensitivity running, I received no warning after scanning. Why?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi Malae,

    That’s a little bit strange, may I know what was the plugin so I can try reproducing this issue at my end?

    Thanks.

    Thread Starter Malae

    (@malae)

    Hi wfalaa,

    Thank you for your quick reply. The plugin is Broken Link Checker version 1.11.5,

    Here are the warnings before changing the code:

    FILE: /wp-content/plugins/broken-link-checker/core/core.php
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
     957 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    
    FILE: /wp-content/plugins/broken-link-checker/modules/checkers/http.php
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
     147 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead

    After waiting for 3 months with no reply from the author, I changed the code to use anonymous functions. I commented out the lines with the deprecated code and added comments.

    The plugin appears to be working with no warnings. Is it possible that I have a syntax error in my code that could interfere with the detection of the changes?

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Modified plugin files not detected.’ is closed to new replies.