Make WordPress Core

Changeset 44706


Ignore:
Timestamp:
01/28/2019 05:42:55 PM (5 years ago)
Author:
flixos90
Message:

Bootstrap/Load: Fix notice when theme directories are not populated yet.

When a fatal error occurs outside of a regular plugin in a stage where theme directories are not set up yet (for example in a MU plugin), this would previously trigger a notice.

Props johnbillion.
Fixes #46068. See #44458.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/error-protection.php

    r44674 r44706  
    6969        $path     = str_replace( $wp_plugin_dir . '/', '', $error_file );
    7070    } else {
     71        if ( empty( $wp_theme_directories ) ) {
     72            return false;
     73        }
     74
    7175        foreach ( $wp_theme_directories as $theme_directory ) {
    7276            $theme_directory = wp_normalize_path( $theme_directory );
Note: See TracChangeset for help on using the changeset viewer.