WordPress.org

Make WordPress Core

Ticket #35521: 35521.2.diff

File 35521.2.diff, 479 bytes (added by swissspidy, 3 years ago)
  • src/wp-admin/theme-install.php

    diff --git src/wp-admin/theme-install.php src/wp-admin/theme-install.php
    index b3eff07ae8..32a773c11b 100644
    if ( ! is_network_admin() ) { 
    2828}
    2929
    3030$installed_themes = search_theme_directories();
     31
     32if ( false === $installed_themes ) {
     33        $installed_themes = array();
     34}
     35
    3136foreach ( $installed_themes as $k => $v ) {
    3237        if ( false !== strpos( $k, '/' ) ) {
    3338                unset( $installed_themes[ $k ] );