Notice fix from apokalyptik

git-svn-id: http://svn.automattic.com/wordpress/trunk@10225 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2008-12-18 22:26:03 +00:00
parent 471e08956d
commit b117040958
1 changed files with 5 additions and 3 deletions

View File

@ -1041,9 +1041,11 @@ function remove_option_whitelist( $del_options, $options = '' ) {
}
foreach( $del_options as $page => $keys ) {
foreach( $keys as $key ) {
$pos = array_search( $key, $whitelist_options[ $page ] );
if( $pos !== false )
unset( $whitelist_options[ $page ][ $pos ] );
if ( isset($whitelist_options[ $page ]) && is_array($whitelist_options[ $page ]) ) {
$pos = array_search( $key, $whitelist_options[ $page ] );
if( $pos !== false )
unset( $whitelist_options[ $page ][ $pos ] );
}
}
}
return $whitelist_options;