WP_Community_Events::get_cached_events(): array|false

In this article

Gets cached events.

Return

array|false An array containing location and events items on success, false on failure.

Source

public function get_cached_events() {	$transient_key = $this->get_events_transient_key( $this->user_location );	if ( ! $transient_key ) {	return false;	}	$cached_response = get_site_transient( $transient_key );	if ( isset( $cached_response['events'] ) ) {	$cached_response['events'] = $this->trim_events( $cached_response['events'] );	}	return $cached_response; } 

Changelog

VersionDescription
5.5.2Response no longer contains formatted date field. They’re added in wp.communityEvents.populateDynamicEventFields() now.
4.8.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.