Make WordPress Core


Ignore:
Timestamp:
05/06/2010 07:53:40 PM (14 years ago)
Author:
nacin
Message:

Remove WP_FALLBACK_THEME, use WP_DEFAULT_THEME instead. We now only fall back to the default theme if the theme is broken. Incomplete themes that need to inherit templates will inherit them from wp-includes/theme-compat -- this behavior is deprecated. fixes #12846.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/theme.php

    r14409 r14485  
    12081208 * Checks that current theme files 'index.php' and 'style.css' exists.
    12091209 *
    1210  * Does not check the fallback theme. The fallback theme should always exist.
     1210 * Does not check the default theme, which is the fallback and should always exist.
    12111211 * Will switch theme to the fallback theme if current theme does not validate.
    12121212 * You can use the 'validate_current_theme' filter to return FALSE to
     
    12141214 *
    12151215 * @since 1.5.0
    1216  * @see WP_FALLBACK_THEME
     1216 * @see WP_DEFAULT_THEME
    12171217 *
    12181218 * @return bool
     
    12231223        return true;
    12241224
    1225     if ( get_template() != WP_FALLBACK_THEME && !file_exists(get_template_directory() . '/index.php') ) {
    1226         switch_theme( WP_FALLBACK_THEME, WP_FALLBACK_THEME );
     1225    if ( get_template() != WP_DEFAULT_THEME && !file_exists(get_template_directory() . '/index.php') ) {
     1226        switch_theme( WP_DEFAULT_THEME, WP_DEFAULT_THEME );
    12271227        return false;
    12281228    }
    12291229
    1230     if ( get_stylesheet() != WP_FALLBACK_THEME && !file_exists(get_template_directory() . '/style.css') ) {
    1231         switch_theme( WP_FALLBACK_THEME, WP_FALLBACK_THEME );
     1230    if ( get_stylesheet() != WP_DEFAULT_THEME && !file_exists(get_template_directory() . '/style.css') ) {
     1231        switch_theme( WP_DEFAULT_THEME, WP_DEFAULT_THEME );
    12321232        return false;
    12331233    }
Note: See TracChangeset for help on using the changeset viewer.