8000 [Cache] Add type to redis scan call to avoid using default "" which r… · symfony/symfony@386bef4 · GitHub
[go: up one dir, main page]

Skip to content

Commit 386bef4

Browse files
committed
[Cache] Add type to redis scan call to avoid using default "" which returns empty array
1 parent 664166c commit 386bef4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/Cache/Traits/RedisTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -485,7 +485,7 @@ protected function doClear(string $namespace): bool
485485

486486
$cursor = null;
487487
do {
488-
$keys = $host instanceof \Predis\ClientInterface ? $host->scan($cursor, 'MATCH', $pattern, 'COUNT', 1000) : $host->scan($cursor, $pattern, 1000);
488+
$keys = $host instanceof \Predis\ClientInterface ? $host->scan($cursor, 'MATCH', $pattern, 'COUNT', 1000) : $host->scan($cursor, $pattern, 1000, 'string');
489489
if (isset($keys[1]) && \is_array($keys[1])) {
490490
$cursor = $keys[0];
491491
$keys = $keys[1];

0 commit comments

Comments
 (0)
0