Skip to content

Commit 9c7e18d

Browse files
committed
Fix select hash key
1 parent 4a94cb4 commit 9c7e18d

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

src/Database/Database.php

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6460,12 +6460,11 @@ public function getCacheKeys(string $collectionId, ?string $documentId = null, a
64606460
}
64616461

64626462
if ($documentId) {
6463-
$documentKey = "{$collectionKey}:{$documentId}";
6464-
}
6463+
$documentKey = $documentHashKey = "{$collectionKey}:{$documentId}";
64656464

6466-
if ($documentId && !empty($selects)) {
6467-
$hash = \md5(\implode($selects));
6468-
$documentHashKey = "{$documentKey}:{$hash}";
6465+
if (!empty($selects)) {
6466+
$documentHashKey = $documentKey . ':' . \md5(\implode($selects));
6467+
}
64696468
}
64706469

64716470
return [

0 commit comments

Comments
 (0)