aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVictor Dubiniuk <victor.dubiniuk@gmail.com>2019-09-10 12:06:33 +0300
committerbackportbot[bot] <backportbot[bot]@users.noreply.github.com>2024-11-08 16:14:47 +0000
commite1df152eb9504c57ff2c1d42ac33464c88d9537c (patch)
treec282c3f8ce643c010f4b2d0baa9a49c41504a284
parentcc1197d568a9edfaeb6836328f3adb5b88ae9fb1 (diff)
downloadnextcloud-server-e1df152eb9504c57ff2c1d42ac33464c88d9537c.tar.gz
nextcloud-server-e1df152eb9504c57ff2c1d42ac33464c88d9537c.zip
Fix Undefined variable: response notice in case of non-404 errorbackport/49146/stable30
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
-rw-r--r--lib/private/Files/Storage/DAV.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/private/Files/Storage/DAV.php b/lib/private/Files/Storage/DAV.php
index 63ef1399a69..e2df66cb054 100644
--- a/lib/private/Files/Storage/DAV.php
+++ b/lib/private/Files/Storage/DAV.php
@@ -253,6 +253,7 @@ class DAV extends Common {
// we either don't know it, or we know it exists but need more details
if (is_null($cachedResponse) || $cachedResponse === true) {
$this->init();
+ $response = false;
try {
$response = $this->client->propFind(
$this->encodePath($path),
@@ -263,9 +264,9 @@ class DAV extends Common {
if ($e->getHttpStatus() === 404 || $e->getHttpStatus() === 405) {
$this->statCache->clear($path . '/');
$this->statCache->set($path, false);
- return false;
+ } else {
+ $this->convertException($e, $path);
}
- $this->convertException($e, $path);
} catch (\Exception $e) {
$this->convertException($e, $path);
}