Make WordPress Core

Changeset 21127

Timestamp:
06/26/2012 03:36:44 AM (12 years ago)
Author:
nacin
Message:

When looking in a sub-directory of wp-content/themes for more themes, check
if that specific directory exists before looking inside of it for style.css.

This avoids warnings when open_basedir restrictions are in effect.

props goldenapples. fixes #20985 for 3.4.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.4/wp-includes/theme.php

    r21063 r21127  
    382382                    return false;
    383383                foreach ( $sub_dirs as $sub_dir ) {
    384                     if ( ! is_dir( $theme_root . '/' . $dir ) || $dir[0] == '.' || $dir == 'CVS' )
     384                    if ( ! is_dir( $theme_root . '/' . $dir ) || $dir[0] == '.' || $dir == 'CVS' )
    385385                        continue;
    386386                    if ( ! file_exists( $theme_root . '/' . $dir . '/' . $sub_dir . '/style.css' ) )
Note: See TracChangeset for help on using the changeset viewer.