Tribe__Tickets_Plus__Commerce__WooCommerce__Meta::delete_hash_cookie( int $ticket_id )
Delete the hash value from the WooCommerce session.
Contents
Parameters
- $ticket_id
-
(int) (Required) The ticket ID.
Source
File: src/Tribe/Commerce/WooCommerce/Meta.php
public function delete_hash_cookie( $ticket_id ) {
if ( 'product' !== get_post_type( $ticket_id ) ) {
return;
}
$wc_session = WC()->session;
if ( empty( $wc_session ) ) {
return;
}
$wc_session->__unset( Tribe__Tickets_Plus__Meta__Storage::HASH_COOKIE_KEY );
}
Changelog
| Version | Description |
|---|---|
| 4.11.0 | Introduced. |