Fix undefined variable slug on theme activation error (https://github.com/woocommerce/woocommerce-admin/pull/3942)
This commit is contained in:
parent
7777a7b727
commit
57f8cbf3e8
|
@ -168,6 +168,7 @@ class OnboardingThemes extends \WC_REST_Data_Controller {
|
|||
|
||||
require_once ABSPATH . 'wp-admin/includes/theme.php';
|
||||
|
||||
$slug = sanitize_key( $theme );
|
||||
$installed_themes = wp_get_themes();
|
||||
|
||||
if ( ! in_array( $theme, array_keys( $installed_themes ), true ) ) {
|
||||
|
|
Loading…
Reference in New Issue