Skip to content

Commit

Permalink
fix: don't show the admin setup wizard who ran the setup wizard before
Browse files Browse the repository at this point in the history
  • Loading branch information
saimonh3 committed Dec 24, 2019
1 parent d2e1414 commit bb01fd1
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions dokan.php
Original file line number Diff line number Diff line change
Expand Up @@ -544,6 +544,14 @@ public function render_run_admin_setup_wizard_notice() {
return;
}

// If vendor found, don't show the setup wizard as admin already ran the `setup wizard`
// without the `dokan_admin_setup_wizard_ready` option.
$vendor_count = dokan_get_seller_status_count();

if ( ! empty( $vendor_count['active'] ) ) {
return update_option( 'dokan_admin_setup_wizard_ready', true );
}

require_once DOKAN_INC_DIR . '/functions.php';

dokan_get_template( 'admin-setup-wizard/run-wizard-notice.php' );
Expand Down

0 comments on commit bb01fd1

Please sign in to comment.