1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2025-12-12 23:34:03 +00:00

Make Cache::tags() support named parameters (fix #1256)

This commit is contained in:
Samuel Štancl 2024-09-17 18:09:49 +02:00 committed by GitHub
parent f2e1648973
commit ed029438cb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -26,7 +26,7 @@ class CacheManager extends BaseCacheManager
throw new \Exception("Method tags() takes exactly 1 argument. $count passed.");
}
$names = $parameters[0];
$names = array_values($parameters)[0];
$names = (array) $names; // cache()->tags('foo') https://laravel.com/docs/5.7/cache#removing-tagged-cache-items
return $this->store()->tags(array_merge($tags, $names));