From a71c9d98f287113130294885ea2169310cab78a1 Mon Sep 17 00:00:00 2001 From: Matt Mullenweg Date: Mon, 9 Aug 2004 07:54:23 +0000 Subject: [PATCH] Don't need the 1=1 git-svn-id: https://develop.svn.wordpress.org/trunk@1523 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/functions.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/wp-includes/functions.php b/wp-includes/functions.php index 0f7134f2e1..5533e06760 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -322,7 +322,8 @@ function get_alloptions() { if ('siteurl' == $option->option_name) $option->option_value = preg_replace('|/+$|', '', $option->option_value); if ('home' == $option->option_name) $option->option_value = preg_replace('|/+$|', '', $option->option_value); if ('category_base' == $option->option_name) $option->option_value = preg_replace('|/+$|', '', $option->option_value); - if (@ $value = unserialize($option->option_value) ) return $value; + if (@ $value = unserialize($option->option_value) ) + $all_options->{$option->option_name} = $value; else $value = $option->option_value; $all_options->{$option->option_name} = $value; } @@ -1509,7 +1510,7 @@ function update_post_caches($posts) { function update_category_cache() { global $cache_categories, $wpdb; - $dogs = $wpdb->get_results("SELECT * FROM $wpdb->categories WHERE 1=1"); + $dogs = $wpdb->get_results("SELECT * FROM $wpdb->categories"); foreach ($dogs as $catt) { $cache_categories[$catt->cat_ID] = $catt; }