From 5d4fca30887573d6abbfda485c60d0531cab908a Mon Sep 17 00:00:00 2001 From: rboren Date: Tue, 8 Jun 2004 09:34:01 +0000 Subject: [PATCH] Add null check to $functions in apply_filters(). http://www.kackreiz.net/wordpress.php git-svn-id: http://svn.automattic.com/wordpress/trunk@1394 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/functions.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/wp-includes/functions.php b/wp-includes/functions.php index f40e0723d0..3af727e25a 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -1117,9 +1117,11 @@ function apply_filters($tag, $string) { if (isset($wp_filter[$tag])) { ksort($wp_filter[$tag]); foreach ($wp_filter[$tag] as $priority => $functions) { - foreach($functions as $function) { + if (!is_null($functions)) { + foreach($functions as $function) { $string = $function($string); - } + } + } } } return $string;