wpsharks / comet-cache

An advanced WordPress® caching plugin inspired by simplicity.
https://cometcache.com
GNU General Public License v3.0
76 stars 17 forks source link

TokenUtils.php error #845

Closed hamellr closed 7 years ago

hamellr commented 7 years ago

Warning: in_array() expects parameter 2 to be array, boolean given in /home/novacom/public_html/wp-content/plugins/comet-cache-pro/src/includes/traits/Shared/TokenUtils.php on line 198

This comes up on both of my Wordpress Installs, one is MU, one is single user. No changes made in themes, new plugins, code etc. I've been getting this error message since the last Comet Cache Update.

Error shows up when updating Plugins, Approving Comments, and occasionally when posting.

raamdev commented 7 years ago

@hamellr Thank you for the report. Can you tell me which version of PHP, WordPress, and Comet Cache you're running please?

raamdev commented 7 years ago

Haven't been able to reproduce this. Closing due to lack of feedback.

peowpeow commented 7 years ago

Hello, I have same problem on MU install. After setting up Comments settings on one subsite.

Warning: in_array() expects parameter 2 to be array, boolean given in /home/novacom/public_html/wp-content/plugins/comet-cache-pro/src/includes/traits/Shared/TokenUtils.php on line 189

PHP is version 5.4.42, Comet Cache newest, Wordpress too.

raamdev commented 7 years ago

@peowpeow Thank you for the feedback.

@renzms Could you please try to reproduce this on multisite with PHP v5.4?

renzms commented 7 years ago

@raamdev

Unable to reproduce bug

WordPress Version: 4.7 Current WordPress Theme: Twenty Sixteen version 1.3 Active Plugins: Comet Cache Pro v161226 PHP Version: 5.4.45 MySQL Version: 10.0.28-MariaDB-0ubuntu0.16.04.1 Apache Version: Apache/2.4.10 (Debian)

Tested using Multisite. Created test posts, managed comments, updated and added plugins for Child sites.

Anything else specific that I could try?

raamdev commented 7 years ago

@renzms Did you try specifically saving the Discussion settings on a child site?

peowpeow commented 7 years ago

Edit: currently I have found out that it is server-specific on our side. I have tested copy of installation on different server and everything runs fine.

renzms commented 7 years ago

Did you try specifically saving the Discussion settings on a child site?

@raamdev Yes, when I changed the settings to manually approve comments. 😃

Customer has updated their comment above, and it seems it was a server specific error.

peowpeow commented 7 years ago

After testing on different machines it was because 1)php version - on second was 5.6, on first 5.4. and/or 2) low memory (set limit on wordpress folder and/or only 64mb ram allowed).

Thank you for this great caching plugin, always our number one on every project.

raamdev commented 7 years ago

@peowpeow Thanks for the update! :-) If you haven't already, we'd LOVE a review on WordPress.org: https://wordpress.org/support/plugin/comet-cache/reviews/?filter=5 😃