Title: Solid, needs some polishing
Last modified: March 17, 2025

---

# Solid, needs some polishing

 *  [sgpro](https://wordpress.org/support/users/sgpro/)
 * (@sgpro)
 * [1 year ago](https://wordpress.org/support/topic/solid-needs-some-polishing/)
 * Hey Chris, when setting a potentially faulty redis config, the plugin breaks
 * `PHP Fatal error: Uncaught Error: Call to a member function setOption() on null
   in pathtowordpress/plugins/mega-cache/includes/atec-wpmc-connect-redis.php:30`
 * Here’s the problematic line:
 * `if (($rdSettings['serializer']??0)!==0) @$atec_wpmc_source['redis']->setOption(
   Redis::OPT_SERIALIZER, $rdSettings['serializer']);`
 * A Redis option (`Redis::OPT_SERIALIZER`) is only set if the `'serializer'` key
   exists and isn’t 0 in`$rdSettings`, but if the Redis connection doesn’t succeed
   due to a bad config, then`$atec_wpmc_source['redis']` will be set to `null` within
   that `catch` block, so the plugin should only set the option if the Redis connection
   was successful, like if `$atec_wpmc_source['redis']` isnt `null`

Viewing 1 replies (of 1 total)

 *  Plugin Author [docjojo](https://wordpress.org/support/users/docjojo/)
 * (@docjojo)
 * [1 year ago](https://wordpress.org/support/topic/solid-needs-some-polishing/#post-18366659)
 * Thank you for your report, I have fixed that and uploaded v1.0.54.
   Would you 
   mind testing it on your system and let me know?

Viewing 1 replies (of 1 total)

The topic ‘Solid, needs some polishing’ is closed to new replies.

 * ![](https://ps.w.org/mega-cache/assets/icon.svg?rev=3198507)
 * [Mega Cache](https://wordpress.org/plugins/mega-cache/)
 * [Support Threads](https://wordpress.org/support/plugin/mega-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/mega-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/mega-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/mega-cache/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [docjojo](https://wordpress.org/support/users/docjojo/)
 * Last activity: [1 year ago](https://wordpress.org/support/topic/solid-needs-some-polishing/#post-18366659)