WordPress at Your Fingertips
function is not described

WC_REST_Authentication::check_authentication_error() public WC 1.0

Check for authentication error.

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

No Hooks.

Return

WP_Error|null|true|false.

Usage

$WC_REST_Authentication = new WC_REST_Authentication();
$WC_REST_Authentication->check_authentication_error( $error );
$error(WP_Error|null|true|false) (required)
Error data.

Code of WC_REST_Authentication::check_authentication_error() WC 5.9.0

public function check_authentication_error( $error ) {
	// Pass through other errors.
	if ( ! empty( $error ) ) {
		return $error;
	}

	return $this->get_error();
}