From d96e57bed8e9b2b83b1233248b1bdfbfb99e0b03 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Fri, 29 Oct 2010 22:44:05 +0000 Subject: [PATCH] Prevent network creation when OMG_DO_NOT_UPGRADE_GLOBAL_TABLES is defined. props wpmuguru, fixes #14246. git-svn-id: https://develop.svn.wordpress.org/trunk@16094 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/network.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/wp-admin/network.php b/wp-admin/network.php index 7d6c788552..b78fb73e45 100644 --- a/wp-admin/network.php +++ b/wp-admin/network.php @@ -130,6 +130,13 @@ function network_step1( $errors = false ) { die(); } + if ( defined('DO_NOT_UPGRADE_GLOBAL_TABLES') ) { + echo '

' . __('Error:') . ' ' . __( 'The constant DO_NOT_UPGRADE_GLOBAL_TABLES cannot be defined when creating a network.' ) . '

'; + echo ''; + include ('./admin-footer.php' ); + die(); + } + $active_plugins = get_option( 'active_plugins' ); if ( ! empty( $active_plugins ) ) { echo '

' . __('Warning:') . ' ' . sprintf( __( 'Please deactivate your plugins before enabling the Network feature.' ), admin_url( 'plugins.php?plugin_status=active' ) ) . '

' . __( 'Once the network is created, you may reactivate your plugins.' ) . '

';