WP_Object_Cache::delete_multiple()publicWP 6.0.0

Deletes multiple values from the cache in one call.

{} Это метод класса: WP_Object_Cache{}

Хуков нет.

Возвращает

true|false[]. Array of return values, grouped by key. Each value is either true on success, or false if the contents were not deleted.

Использование

$WP_Object_Cache = new WP_Object_Cache();
$WP_Object_Cache->delete_multiple( $keys, $group );
$keys(массив) (обязательный)
Array of keys to be deleted.
$group(строка)
Where the cache contents are grouped.
По умолчанию: ''

Список изменений

С версии 6.0.0 Введена.

Код WP_Object_Cache::delete_multiple() WP 6.0.2

public function delete_multiple( array $keys, $group = '' ) {
	$values = array();

	foreach ( $keys as $key ) {
		$values[ $key ] = $this->delete( $key, $group );
	}

	return $values;
}