]> source.dussan.org Git - nextcloud-server.git/commitdiff
Properly return an int in the getId function of the cache 16686/head
authorRoeland Jago Douma <roeland@famdouma.nl>
Wed, 7 Aug 2019 18:38:42 +0000 (20:38 +0200)
committerRoeland Jago Douma <roeland@famdouma.nl>
Wed, 7 Aug 2019 18:38:42 +0000 (20:38 +0200)
fixes #16684

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
lib/private/Files/Cache/Cache.php

index 6958e07be564a28967d1a8deb73bae89b10e741b..f6139d8abed7f1f5189ef986abadb6407bf7a673 100644 (file)
@@ -416,7 +416,7 @@ class Cache implements ICache {
                $sql = 'SELECT `fileid` FROM `*PREFIX*filecache` WHERE `storage` = ? AND `path_hash` = ?';
                $result = $this->connection->executeQuery($sql, array($this->getNumericStorageId(), $pathHash));
                if ($row = $result->fetch()) {
-                       return $row['fileid'];
+                       return (int)$row['fileid'];
                } else {
                        return -1;
                }