maybe_disable_link_manager() – Disables the Link Manager on upgrade if, at the time of upgrade, no links exist in the DB.

You appear to be a bot. Output may be restricted

Description

Disables the Link Manager on upgrade if, at the time of upgrade, no links exist in the DB.

Usage

maybe_disable_link_manager();

Parameters

Returns

void

Source

File name: wordpress/wp-admin/includes/upgrade.php
Lines:

1 to 7 of 7
function maybe_disable_link_manager() {
  global $wp_current_db_version, $wpdb;

  if ( $wp_current_db_version >= 22006 && get_option( 'link_manager_enabled' ) && ! $wpdb->get_var( "SELECT link_id FROM $wpdb->links LIMIT 1" ) ) {
    update_option( 'link_manager_enabled', 0 );
  }
}
 

 View on GitHub View on Trac