WordPress at Your Fingertips
function is not described

WC_WCCOM_Site_Installer::finish_installation() private WC 3.7.0

Finish installation by updating the state.

{} It's a method of the class: WC_WCCOM_Site_Installer{}

No Hooks.

Return

null. Nothing.

Usage

$result = WC_WCCOM_Site_Installer::finish_installation();

Changelog

Since 3.7.0 Introduced.

Code of WC_WCCOM_Site_Installer::finish_installation() WC 5.6.0

private static function finish_installation() {
	$state = self::get_state();
	if ( empty( $state['steps'] ) ) {
		return;
	}

	foreach ( $state['steps'] as $step ) {
		if ( ! empty( $step['last_error'] ) ) {
			$state['status'] = 'has_error';
			break;
		}
	}

	if ( 'has_error' !== $state['status'] ) {
		$state['status'] = 'finished';
	}

	WC_Helper_Options::update( 'product_install', $state );
}