• Resolved ElectricFeet

    (@electricfeet)


    The following is used in the plugin (on line 106 of auto-hide-admin-bar.php):

    if (function_exists('get_current_theme')) {
            $theme_name = get_current_theme();
        };

    WP_DEBUG is telling me that get_current_theme is deprecated. Could the following be used instead?

    if (function_exists('wp_get_theme')) {
        $theme_name = ( wp_get_theme()->Template );
    };

    (Or change the variable name to $theme_parent would perhaps be better — also on line 117.)

    This would also have the advantage of picking up children of Twenty Fourteen as well, which presumably would need the same fix.

    https://wordpress.org/plugins/auto-hide-admin-bar/

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘WP_DEBUG gives message that get_current_theme is deprecated’ is closed to new replies.