Cast to array to avoid warning.
git-svn-id: http://svn.automattic.com/wordpress/branches/2.2@5431 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
c22a4ed9f1
commit
cc6a998e20
|
@ -1112,7 +1112,7 @@ function wp_check_mysql_version() {
|
||||||
function maybe_disable_automattic_widgets() {
|
function maybe_disable_automattic_widgets() {
|
||||||
$plugins = __get_option( 'active_plugins' );
|
$plugins = __get_option( 'active_plugins' );
|
||||||
|
|
||||||
foreach ( $plugins as $plugin ) {
|
foreach ( (array) $plugins as $plugin ) {
|
||||||
if ( basename( $plugin ) == 'widgets.php' ) {
|
if ( basename( $plugin ) == 'widgets.php' ) {
|
||||||
array_splice( $plugins, array_search( $plugin, $plugins ), 1 );
|
array_splice( $plugins, array_search( $plugin, $plugins ), 1 );
|
||||||
update_option( 'active_plugins', $plugins );
|
update_option( 'active_plugins', $plugins );
|
||||||
|
|
Loading…
Reference in New Issue