Automattic\WooCommerce\Admin\Features\OnboardingTasks\Tasks

Payments::is_completepublicWC 1.0

Task completion.

Method of the class: Payments{}

No Hooks.

Returns

true|false.

Usage

$Payments = new Payments();
$Payments->is_complete();

Payments::is_complete() code WC 10.4.3

public function is_complete() {
	if ( null === $this->is_complete_result ) {
		if ( $this->is_woopayments_active() ) {
			// If WooPayments is active, check if it is fully onboarded with a live account.
			$this->is_complete_result = $this->is_woopayments_onboarded() && ! $this->has_woopayments_test_account();
		} else {
			// If WooPayments is not active, check if there are any enabled gateways.
			$this->is_complete_result = self::has_gateways();
		}
	}

	return $this->is_complete_result;
}