mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-04-05 05:04:31 +00:00
Cast to array when using foreach(). Props santosj (and thanks for your perseverance!). fixes #2784
git-svn-id: https://develop.svn.wordpress.org/trunk@8572 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -90,7 +90,7 @@ function has_filter($tag, $function_to_check = false) {
|
||||
if ( !$idx = _wp_filter_build_unique_id($tag, $function_to_check, false) )
|
||||
return false;
|
||||
|
||||
foreach ( array_keys($wp_filter[$tag]) as $priority ) {
|
||||
foreach ( (array) array_keys($wp_filter[$tag]) as $priority ) {
|
||||
if ( isset($wp_filter[$tag][$priority][$idx]) )
|
||||
return $priority;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user