Make WordPress Core


Ignore:
Timestamp:
07/09/2024 01:51:12 PM (2 years ago)
Author:
SergeyBiryukov
Message:

REST API: Remove a few unused variables in foreach loops.

Follow-up to [38832], [48173], [49132], [49925].

Props antonvlasenko.
See #61593.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-themes-controller.php

    r58408 r58694  
    202202                $status        = $request['status'];
    203203
    204                 foreach ( $active_themes as $theme_name => $theme ) {
     204                foreach ( $active_themes as $theme ) {
    205205                        $theme_status = ( $this->is_same_theme( $theme, $current_theme ) ) ? 'active' : 'inactive';
    206206                        if ( is_array( $status ) && ! in_array( $theme_status, $status, true ) ) {
Note: See TracChangeset for help on using the changeset viewer.