aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorRobin Appelman <robin@icewind.nl>2023-02-06 18:17:40 +0100
committerRobin Appelman <robin@icewind.nl>2023-02-06 18:17:40 +0100
commit9281359fa47b5b67d09b0661bdfb0dcee9795b54 (patch)
tree6917ed39567da6e8f51d2f0fb82a3be7fb37a388 /lib
parent43589312ccbdf977bb6d89eae3bec28bde2dceff (diff)
downloadnextcloud-server-9281359fa47b5b67d09b0661bdfb0dcee9795b54.tar.gz
nextcloud-server-9281359fa47b5b67d09b0661bdfb0dcee9795b54.zip
deduplicate getStorage() logic in Mount\Manager
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Files/Mount/MountPoint.php10
1 files changed, 1 insertions, 9 deletions
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);
}