From: Robin Appelman Date: Mon, 6 Feb 2023 17:17:40 +0000 (+0100) Subject: deduplicate getStorage() logic in Mount\Manager X-Git-Tag: v26.0.0beta3~6^2~2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=9281359fa47b5b67d09b0661bdfb0dcee9795b54;p=nextcloud-server.git deduplicate getStorage() logic in Mount\Manager Signed-off-by: Robin Appelman --- diff --git a/lib/private/Files/Mount/MountPoint.php b/lib/private/Files/Mount/MountPoint.php index 49f7e560ad3..770655fae50 100644 --- a/lib/private/Files/Mount/MountPoint.php +++ b/lib/private/Files/Mount/MountPoint.php @@ -199,15 +199,7 @@ class MountPoint implements IMountPoint { */ public function getStorageId() { if (!$this->storageId) { - if (is_null($this->storage)) { - $storage = $this->createStorage(); //FIXME: start using exceptions - if (is_null($storage)) { - return null; - } - - $this->storage = $storage; - } - $this->storageId = $this->storage->getId(); + $this->storageId = $this->getStorage()->getId(); if (strlen($this->storageId) > 64) { $this->storageId = md5($this->storageId); }