WordPress.org

Make WordPress Core

Ticket #16055: 16055-1.patch

File 16055-1.patch, 803 bytes (added by DJPaul, 3 years ago)
  • wp-admin/includes/plugin.php

     
    8888        $plugin_data = get_file_data( $plugin_file, $default_headers, 'plugin' ); 
    8989 
    9090        // Site Wide Only is the old header for Network 
    91         if ( empty( $plugin_data['Network'] ) && ! empty( $plugin_data['_sitewide'] ) ) { 
     91        if ( empty( $plugin_data['Network'] ) && ! empty( $plugin_data['_sitewide'] ) && is_plugin_active( $plugin_file ) ) { 
    9292                _deprecated_argument( __FUNCTION__, '3.0', sprintf( __( 'The <code>%1$s</code> plugin header is deprecated. Use <code>%2$s</code> instead.' ), 'Site Wide Only: true', 'Network: true' ) ); 
    9393                $plugin_data['Network'] = $plugin_data['_sitewide']; 
    9494        }