Cast to array

git-svn-id: http://svn.automattic.com/wordpress/trunk@7081 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2008-02-28 06:43:45 +00:00
parent b2838e11c7
commit c313442072
1 changed files with 1 additions and 1 deletions

View File

@ -551,7 +551,7 @@ class Walker_Page extends Walker {
extract($args, EXTR_SKIP);
$css_class = 'page_item page-item-'.$page->ID;
$_current_page = get_page( $current_page );
if ( in_array($page->ID, $_current_page->ancestors) )
if ( in_array($page->ID, (array) $_current_page->ancestors) )
$css_class .= ' current_page_ancestor';
if ( $page->ID == $current_page )
$css_class .= ' current_page_item';