Support » Plugin: Wordfence Security - Firewall & Malware Scan » “expects parameter 2 to be array” error breaking site

  • Resolved greencode


    I’ve just updated to 7.1.11 from 7.1.10 however the site no longer loads and I’ve noticed hundreds of lines in the error log:

    [24-Aug-2018 14:32:47 Europe/London] PHP Warning: array_key_exists() expects parameter 2 to be array, boolean given in /home/mysite/public_html/wp-content/plugins/wordfence/vendor/wordfence/wf-waf/src/lib/storage/file.php on line 478

    I’ve reverted back to 7.1.10 but that error is still happening. The site is now loading though, for the time being.

    Any ideas?

Viewing 4 replies - 1 through 4 (of 4 total)
  • delete whole wordfence, run few minutes without wordfence then again install latest version.

    Hi @greencode

    This issue could be related to a broken firewall configuration file, I suggest deleting “wflogs” folder under “/wp-content/” directory then reload any of the plugin’s settings page to get this folder regenerated, after that recheck this issue and let me know how it goes.

    Don’t forget to switch the firewall into “Enabled and Protecting” after doing this step.


    I decided to do a completely manual uninstall of the plugin and start again. All seems to be working well, so far, with no errors in the log. I’ll update this thread again in a few days.

    Just to let you know that this issue just affected on of my sites running Wordfence too. I did as @wfalaa suggested and the solution worked. I first deactivated the plugin by ftp and the site came back online. I deleted the “wflogs” folder and re-activated the plugin. All is well now.
    Thanks for the support. Very timely.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘“expects parameter 2 to be array” error breaking site’ is closed to new replies.