Fix DB upgrade kickoff for removal of usermeta fields. See r14212, r14213, see #13032

git-svn-id: http://svn.automattic.com/wordpress/trunk@14218 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
dd32 2010-04-24 10:29:01 +00:00
parent 79dea16d7f
commit d0cb517220
2 changed files with 3 additions and 3 deletions

View File

@ -440,7 +440,7 @@ function upgrade_all() {
if ( $wp_current_db_version < 11958 ) if ( $wp_current_db_version < 11958 )
upgrade_290(); upgrade_290();
if ( $wp_current_db_version < 14139 ) if ( $wp_current_db_version < 14217 )
upgrade_300(); upgrade_300();
maybe_disable_automattic_widgets(); maybe_disable_automattic_widgets();
@ -1136,7 +1136,7 @@ function upgrade_300() {
$wpdb->update( $wpdb->postmeta, array( 'meta_value' => '' ), array( 'meta_key' => '_menu_item_target', 'meta_value' => '_self' ) ); $wpdb->update( $wpdb->postmeta, array( 'meta_value' => '' ), array( 'meta_key' => '_menu_item_target', 'meta_value' => '_self' ) );
// 3.0-beta metabox changes. can be removed before release. // r13551 // 3.0-beta metabox changes. can be removed before release. // r13551
if ( ( !is_multisite() || is_main_site() ) && $wp_current_db_version >= 13309 && $wp_current_db_version < 14139 ) if ( ( !is_multisite() || is_main_site() ) && $wp_current_db_version >= 13309 && $wp_current_db_version < 14217 )
$wpdb->query( "DELETE FROM $wpdb->usermeta WHERE meta_key LIKE '{$wpdb->base_prefix}%meta-box-hidden%' OR meta_key LIKE '{$wpdb->base_prefix}%closedpostboxes%'" ); $wpdb->query( "DELETE FROM $wpdb->usermeta WHERE meta_key LIKE '{$wpdb->base_prefix}%meta-box-hidden%' OR meta_key LIKE '{$wpdb->base_prefix}%closedpostboxes%'" );
} }

View File

@ -15,7 +15,7 @@ $wp_version = '3.0-beta1';
* *
* @global int $wp_db_version * @global int $wp_db_version
*/ */
$wp_db_version = 14139; $wp_db_version = 14217;
/** /**
* Holds the TinyMCE version * Holds the TinyMCE version