diff --git a/includes/activitypub/transformer/class-the-events-calendar.php b/includes/activitypub/transformer/class-the-events-calendar.php index 2fe7274..f50fa29 100644 --- a/includes/activitypub/transformer/class-the-events-calendar.php +++ b/includes/activitypub/transformer/class-the-events-calendar.php @@ -121,9 +121,9 @@ final class The_Events_Calendar extends Event { /** * Get the event location. * - * @return Place|array The place/venue if one is set. + * @return ?Place The place/venue if one is set. */ - public function get_location(): Place|null { + public function get_location(): ?Place { // Get short handle for the venues. $venues = $this->tribe_event->venues; diff --git a/includes/class-setup.php b/includes/class-setup.php index 966d1d3..2912002 100644 --- a/includes/class-setup.php +++ b/includes/class-setup.php @@ -252,7 +252,7 @@ class Setup { * * @return \Activitypub\Transformer\Base|null */ - public function register_activitypub_event_transformer( $transformer, $wp_object, $object_class ): \Activitypub\Transformer\Base|null { + public function register_activitypub_event_transformer( $transformer, $wp_object, $object_class ): \Activitypub\Transformer\Base { // If the current WordPress object is not a post (e.g., a WP_Comment), don't change the transformer. if ( 'WP_Post' !== $object_class ) { return $transformer;