From 49e8ab4fd5d1aab430197fda4a25504a0f0aa881 Mon Sep 17 00:00:00 2001 From: Joost de Valk Date: Thu, 5 Feb 2026 12:04:33 +0100 Subject: [PATCH] fix: return option value instead of key in get_option_from_cache The method returned the option name (key) instead of the option value, making the downstream is_array() check always false and the entire legacy option migration block dead code. Co-Authored-By: Claude Opus 4.5 --- inc/hacks.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/hacks.php b/inc/hacks.php index 58d3514..ad905da 100644 --- a/inc/hacks.php +++ b/inc/hacks.php @@ -282,7 +282,7 @@ public function comment_redirect( string $url, WP_Comment $comment ): string { */ private function get_option_from_cache( string $option ) { $options = \wp_load_alloptions(); - return isset( $options[ $option ] ) ? $option : false; + return isset( $options[ $option ] ) ? $options[ $option ] : false; } /**