WP_Object_Cache::delete_multiple() – Method | Developer.WordPress.org
Deletes multiple values from the cache in one call.
Parameters
$keysarrayrequiredArray of keys to be deleted.
$groupstringoptionalWhere the cache contents are grouped. Default empty.
Return
bool[] Array of return values, grouped by key. Each value is either true on success, or false if the contents were not deleted.Source
public function delete_multiple( array $keys, $group = '' ) {
$values = array();
foreach ( $keys as $key ) {
$values[ $key ] = $this->delete( $key, $group );
}
return $values;
}
Changelog
| Version | Description |
|---|---|
| 6.0.0 | Introduced. |