Tribe__Events__Main::default_end_date_for_tickets( string $date, int $post_id )
If tickets don’t have an end date, let’s provide the end date from the event
Contents
Parameters
- $date
-
(string) (Required)
- $post_id
-
(int) (Required)
Return
(string)
Source
File: src/Tribe/Main.php
public function default_end_date_for_tickets( $date, $post_id ) {
$post = get_post( $post_id );
if ( self::POSTTYPE !== $post->post_type ) {
return $date;
}
return tribe_get_end_date( $post_id, false, 'Y-m-d G:i' );
}