Make WordPress Core


Ignore:
Timestamp:
06/16/2023 01:03:00 PM (2 years ago)
Author:
swissspidy
Message:

Bundled Themes: Remove load_theme_textdomain() calls from default themes.

Since WordPress 4.6 introduced just-in-time translation loading, themes and plugins no longer need to manually call load_theme_textdomain/load_plugin_textdomain, unless they are on a version prior to 4.6.

This change removes the load_theme_textdomain() call from Twenty Seventeen and up, since these themes all require at least WordPress 4.7.
On older default themes, load_theme_textdomain() is called conditionally depending on the WordPress version.

Props piyushtekwani.
Fixes #58318.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-content/themes/twentytwenty/functions.php

    r55861 r55929  
    112112    );
    113113
    114     /*
    115      * Make theme available for translation.
    116      * Translations can be filed in the /languages/ directory.
    117      * If you're building a theme based on Twenty Twenty, use a find and replace
    118      * to change 'twentytwenty' to the name of your theme in all the template files.
    119      */
    120     load_theme_textdomain( 'twentytwenty' );
    121 
    122114    // Add support for full and wide align images.
    123115    add_theme_support( 'align-wide' );
Note: See TracChangeset for help on using the changeset viewer.