WP_Feed_Cache_Transient::save( array|SimplePieSimplePie $data ): true

In this article

Saves data to the transient.

Parameters

$dataarray|SimplePieSimplePierequired
Data to save. If passed a SimplePie object, only cache the $data property.

Return

true Always true.

Source

public function save( $data ) {
	if ( $data instanceof SimplePie\SimplePie ) {
		$data = $data->data;
	}

	set_transient( $this->name, $data, $this->lifetime );
	set_transient( $this->mod_name, time(), $this->lifetime );
	return true;
}

Changelog

VersionDescription
2.8.0Introduced.

User Contributed Notes

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