Skip to content

Commit 6b11862

Browse files
authored
Merge pull request #16686 from nextcloud/fix/16684/return_int_getIf
Properly return an int in the getId function of the cache
2 parents 00c1389 + 650927a commit 6b11862

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/private/Files/Cache/Cache.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ public function getId($file) {
416416
$sql = 'SELECT `fileid` FROM `*PREFIX*filecache` WHERE `storage` = ? AND `path_hash` = ?';
417417
$result = $this->connection->executeQuery($sql, array($this->getNumericStorageId(), $pathHash));
418418
if ($row = $result->fetch()) {
419-
return $row['fileid'];
419+
return (int)$row['fileid'];
420420
} else {
421421
return -1;
422422
}

0 commit comments

Comments
 (0)