WC_Admin_Setup_Wizard::should_show_theme()
Deprecated from version 4.6.0. It is no longer supported and can be removed in future releases. It is recommended to replace this function with the same one.
The theme "extra" should only be shown if the current user can modify themes and the store doesn't already have a WooCommerce theme.
Method of the class: WC_Admin_Setup_Wizard{}
No Hooks.
Return
true|false
.
Usage
// protected - for code of main (parent) or child class $result = $this->should_show_theme();
Changelog
Deprecated since | 4.6.0 |
WC_Admin_Setup_Wizard::should_show_theme() WC Admin Setup Wizard::should show theme code WC 8.6.1
protected function should_show_theme() { _deprecated_function( __CLASS__ . '::' . __FUNCTION__, '4.6.0', 'Onboarding is maintained in WooCommerce Admin.' ); $support_woocommerce = current_theme_supports( 'woocommerce' ) && ! wc_is_wp_default_theme_active(); return ( current_user_can( 'install_themes' ) && current_user_can( 'switch_themes' ) && ! is_multisite() && ! $support_woocommerce ); }