Automattic\WooCommerce\Admin\Features\OnboardingTasks

TaskList::possibly_track_completion()publicWC 1.0

Track list completion of viewable tasks.

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

Хуков нет.

Возвращает

null. Ничего.

Использование

$TaskList = new TaskList();
$TaskList->possibly_track_completion();

Код TaskList::possibly_track_completion() WC 6.4.1

public function possibly_track_completion() {
	if ( ! $this->is_complete() ) {
		return;
	}

	if ( $this->has_previously_completed() ) {
		return;
	}

	$completed_lists   = get_option( self::COMPLETED_OPTION, array() );
	$completed_lists[] = $this->get_list_id();
	update_option( self::COMPLETED_OPTION, $completed_lists );
	$this->record_tracks_event( 'tasks_completed' );
}