upgrade_460

Executes changes made in WordPress 4.6.0.

Description

upgrade_460(); 

Usage

  1. if ( !function_exists( 'upgrade_460' ) ) { 
  2. require_once ABSPATH . '/wp-admin/includes/upgrade.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = upgrade_460(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/wp-admin/includes/upgrade.php  
  1. function upgrade_460() { 
  2. global $wp_current_db_version; 
  3.  
  4. // Remove unused post meta. 
  5. if ( $wp_current_db_version < 37854 ) { 
  6. delete_post_meta_by_key( '_post_restored_from' ); 
  7.  
  8. // Remove plugins with callback as an array object/method as the uninstall hook, see #13786. 
  9. if ( $wp_current_db_version < 37965 ) { 
  10. $uninstall_plugins = get_option( 'uninstall_plugins', array() ); 
  11.  
  12. if ( ! empty( $uninstall_plugins ) ) { 
  13. foreach ( $uninstall_plugins as $basename => $callback ) { 
  14. if ( is_array( $callback ) && is_object( $callback[0] ) ) { 
  15. unset( $uninstall_plugins[ $basename ] ); 
  16.  
  17. update_option( 'uninstall_plugins', $uninstall_plugins );