Automattic\WooCommerce\Admin\Features\OnboardingTasks

TaskList::possibly_remove_reminder_bar()public staticWC 1.0

Remove reminder bar four weeks after store creation.

Метод класса: TaskList{}

No Hooks.

Return

null. Nothing.

Usage

$result = TaskList::possibly_remove_reminder_bar();

Code of TaskList::possibly_remove_reminder_bar() WC 7.1.0

public static function possibly_remove_reminder_bar() {
	$bar_hidden            = get_option( self::REMINDER_BAR_HIDDEN_OPTION, 'no' );
	$active_for_four_weeks = WCAdminHelper::is_wc_admin_active_for( WEEK_IN_SECONDS * 4 );

	if ( 'yes' === $bar_hidden || ! $active_for_four_weeks ) {
		return;
	}

	update_option( self::REMINDER_BAR_HIDDEN_OPTION, 'yes' );
}