From 30280a363c2baed352b88eddcf0fd9d180af54c6 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Wed, 7 Nov 2012 18:01:31 +0000 Subject: [PATCH] Remove the post-format-standard term on upgrade if it exists in the database. fixes #20697. git-svn-id: https://develop.svn.wordpress.org/trunk@22422 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/includes/upgrade.php | 4 +++- wp-includes/version.php | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/wp-admin/includes/upgrade.php b/wp-admin/includes/upgrade.php index fc5aa9dce0..0e0e36190b 100644 --- a/wp-admin/includes/upgrade.php +++ b/wp-admin/includes/upgrade.php @@ -399,7 +399,7 @@ function upgrade_all() { if ( $wp_current_db_version < 20080 ) upgrade_340(); - if ( $wp_current_db_version < 21811 ) + if ( $wp_current_db_version < 22422 ) upgrade_350(); maybe_disable_link_manager(); @@ -1204,6 +1204,8 @@ function upgrade_350() { } } + if ( $wp_current_db_version < 22422 && $term = get_term_by( 'slug', 'post-format-standard', 'post_format' ) ) + wp_delete_term( $term->term_id, 'post_format' ); } /** diff --git a/wp-includes/version.php b/wp-includes/version.php index 14b8e538ca..ad3e44cbe2 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -11,7 +11,7 @@ $wp_version = '3.5-beta2-22407'; * * @global int $wp_db_version */ -$wp_db_version = 22006; +$wp_db_version = 22422; /** * Holds the TinyMCE version