Tribe__Tickets__REST__V1__Main::request_has_valid_api_key()
Return if the request has a valid api key.
Return
(bool) True if the request has a valid api key, false otherwise.
Source
File: src/Tribe/REST/V1/Main.php
public function request_has_valid_api_key() : bool {
$option = tribe_get_option( 'tickets-plus-qr-options-api-key', '' );
if ( empty( $option ) ) {
return false;
}
$request_var = tribe_get_request_var( 'api_key' );
if ( empty( $request_var ) || $option !== $request_var ) {
return false;
}
return true;
}
Changelog
| Version | Description |
|---|---|
| 5.5.0 | Introduced. |