Restore crack-headed arg passing to register_sidebar_widget(). fixes #4275 for 2.3
git-svn-id: https://develop.svn.wordpress.org/trunk@5485 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
ab415652d9
commit
3e813379d0
@ -75,9 +75,9 @@ function register_sidebar_widget($name, $output_callback, $classname = '') {
|
||||
|
||||
$id = sanitize_title($name);
|
||||
$options = array();
|
||||
if ( !empty($classname) )
|
||||
if ( !empty($classname) && is_string($classname) )
|
||||
$options['classname'] = $classname;
|
||||
$params = array_slice(func_get_args(), 3);
|
||||
$params = array_slice(func_get_args(), 2);
|
||||
$args = array($id, $name, $output_callback, $options);
|
||||
if ( !empty($params) )
|
||||
$args = array_merge($args, $params);
|
||||
|
Loading…
Reference in New Issue
Block a user