Title: WordPress caught an error
Last modified: July 19, 2022

---

# WordPress caught an error

 *  Resolved [Sean](https://wordpress.org/support/users/sean-h/)
 * (@sean-h)
 * [3 years, 10 months ago](https://wordpress.org/support/topic/wordpress-caught-an-error-3/)
 * Hi there,
 * Got an interesting email, from only one of my 8 sites, all of which are using
   SG Optimizer. I say interesting, because the site didn’t go down and I don’t 
   see anything in the error logs in Site Tools either.
 * I won’t paste the whole email, so this is just a snippet:
 *     ```
       An error of type E_ERROR was caused in line 496 of the file /home/customer/www/thetastychilli.com/public_html/wp-content/plugins/sg-cachepress/core/File_Cacher/File_Cacher.php. Error message: Uncaught TypeError: array_diff(): Argument #1 ($array) must be of type array, bool given in /home/customer/www/thetastychilli.com/public_html/wp-content/plugins/sg-cachepress/core/File_Cacher/File_Cacher.php:496
       Stack trace:
       #0 /home/customer/www/thetastychilli.com/public_html/wp-content/plugins/sg-cachepress/core/File_Cacher/File_Cacher.php(496): array_diff(false, Array)
       ```
   
 * Is this something I need to worry about? Site was running php 8.0 but is now 
   back on 7.4, if that could have anything to do with it.
    -  This topic was modified 3 years, 10 months ago by [Sean](https://wordpress.org/support/users/sean-h/).

Viewing 1 replies (of 1 total)

 *  Plugin Support [Georgi Ganchev](https://wordpress.org/support/users/georgiganchev/)
 * (@georgiganchev)
 * [3 years, 10 months ago](https://wordpress.org/support/topic/wordpress-caught-an-error-3/#post-15837654)
 * Hello [@sean-h](https://wordpress.org/support/users/sean-h/),
 * This error usually happens when there are plugin files are cached and some old
   files are still used after conducting a certain update/modification. This could
   cause temporary errors that resolve themselves once the cache has been cleared.
 * The change of the PHP version is likely to have caused this temporary error and
   you might have received the email once your cron job was executed.
 * Please be aware that your cron job is set to use PHP8 while the website operates
   under PHP7.4 currently. You may want to edit the cron to be under PHP7.4 as well.
 * Best regards,
    Georgi

Viewing 1 replies (of 1 total)

The topic ‘WordPress caught an error’ is closed to new replies.

 * ![](https://ps.w.org/sg-cachepress/assets/icon-256x256.gif?rev=2971889)
 * [Speed Optimizer - The All-In-One Performance-Boosting Plugin](https://wordpress.org/plugins/sg-cachepress/)
 * [Support Threads](https://wordpress.org/support/plugin/sg-cachepress/)
 * [Active Topics](https://wordpress.org/support/plugin/sg-cachepress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/sg-cachepress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/sg-cachepress/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [Georgi Ganchev](https://wordpress.org/support/users/georgiganchev/)
 * Last activity: [3 years, 10 months ago](https://wordpress.org/support/topic/wordpress-caught-an-error-3/#post-15837654)
 * Status: resolved