WordPress.org

Make WordPress Core

Changeset 40636


Ignore:
Timestamp:
05/11/2017 07:20:10 PM (3 years ago)
Author:
swissspidy
Message:

Themes: Avoid PHP warnings in the admin when no theme directory exists.

Props iseulde, chris_dev, swissspidy.
Fixes #35521.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/theme-install.php

    r40586 r40636  
    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, '/' ) ) {
Note: See TracChangeset for help on using the changeset viewer.