WordPress.org

Make WordPress Core

Changeset 16346


Ignore:
Timestamp:
11/13/2010 04:25:56 PM (9 years ago)
Author:
scribu
Message:

Move network only status check out of foreach. See #15318

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/class-wp-plugins-list-table.php

    r16345 r16346  
    192192    function get_sortable_columns() {
    193193        return array(
    194             'name'         => 'name',
     194            'name' => 'name',
    195195        );
    196196    }
     
    308308
    309309        $screen = get_current_screen();
     310
     311        if ( is_multisite() && !$screen->is_network && in_array( $context, array( 'mustuse', 'dropins' ) ) )
     312            return;
    310313
    311314        foreach ( $this->items as $plugin_file => $plugin_data ) {
     
    320323
    321324            if ( 'mustuse' == $context ) {
    322                 if ( is_multisite() && !$screen->is_network )
    323                     continue;
    324325                $is_active = true;
    325326            } elseif ( 'dropins' == $context ) {
    326                 if ( is_multisite() && !$screen->is_network )
    327                     continue;
    328327                $dropins = _get_dropins();
    329328                $plugin_name = $plugin_file;
Note: See TracChangeset for help on using the changeset viewer.