Automattic\WooCommerce\Blocks
RestApi::store_api_authentication() public WC 1.0
The Store API does not require authentication.
{} Это метод класса: RestApi{}
Хуков нет.
Возвращает
\WP_Error/null/true|false
. Ничего.
Использование
$RestApi = new RestApi(); $RestApi->store_api_authentication( $result );
- $result(\WP_Error/разное) (обязательный)
- Error from another authentication handler, null if we should handle it, or another value if not.
Код RestApi::store_api_authentication() RestApi::store api authentication WC 5.2.2
public function store_api_authentication( $result ) {
// Pass through errors from other authentication methods used before this one.
if ( ! empty( $result ) || ! self::is_request_to_store_api() ) {
return $result;
}
return true;
}