aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@users.noreply.github.com>2024-09-17 10:14:14 +0200
committerGitHub <noreply@github.com>2024-09-17 10:14:14 +0200
commit5c507fa934122b6063bf2e1d0e8737f255b60f05 (patch)
treef80eb92e4767c5896eb55e2c2dbea3e306ac007b
parenta26da45571f7900d2d087b473a27db55f78a7241 (diff)
parent063a726280456ca6a7403768d532dd2285c256db (diff)
downloadnextcloud-server-5c507fa934122b6063bf2e1d0e8737f255b60f05.tar.gz
nextcloud-server-5c507fa934122b6063bf2e1d0e8737f255b60f05.zip
Merge pull request #48103 from nextcloud/backport/46218/stable28
-rw-r--r--lib/private/Files/Storage/Local.php2
-rw-r--r--lib/private/Files/Storage/Wrapper/Availability.php1
2 files changed, 2 insertions, 1 deletions
diff --git a/lib/private/Files/Storage/Local.php b/lib/private/Files/Storage/Local.php
index 19e977c43f8..afaddd2b339 100644
--- a/lib/private/Files/Storage/Local.php
+++ b/lib/private/Files/Storage/Local.php
@@ -435,7 +435,7 @@ class Local extends \OC\Files\Storage\Common {
return $result;
}
- public function hash($type, $path, $raw = false) {
+ public function hash($type, $path, $raw = false): string|false {
return hash_file($type, $this->getSourcePath($path), $raw);
}
diff --git a/lib/private/Files/Storage/Wrapper/Availability.php b/lib/private/Files/Storage/Wrapper/Availability.php
index 693d943f0dc..bab43977b60 100644
--- a/lib/private/Files/Storage/Wrapper/Availability.php
+++ b/lib/private/Files/Storage/Wrapper/Availability.php
@@ -334,6 +334,7 @@ class Availability extends Wrapper {
return parent::hash($type, $path, $raw);
} catch (StorageNotAvailableException $e) {
$this->setUnavailable($e);
+ return false;
}
}