aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorRobin Appelman <robin@icewind.nl>2023-02-06 18:20:08 +0100
committerRobin Appelman <robin@icewind.nl>2023-02-06 18:20:08 +0100
commite3bafcc7a813f6adb305c2e35057b925c278d4bd (patch)
tree717358639ce7b5874dd2cb7671f19c26ff60fa43 /lib
parent9281359fa47b5b67d09b0661bdfb0dcee9795b54 (diff)
downloadnextcloud-server-e3bafcc7a813f6adb305c2e35057b925c278d4bd.tar.gz
nextcloud-server-e3bafcc7a813f6adb305c2e35057b925c278d4bd.zip
cache numeric id in mountpoint
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Files/Mount/MountPoint.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/private/Files/Mount/MountPoint.php b/lib/private/Files/Mount/MountPoint.php
index 770655fae50..67601f016be 100644
--- a/lib/private/Files/Mount/MountPoint.php
+++ b/lib/private/Files/Mount/MountPoint.php
@@ -44,6 +44,7 @@ class MountPoint implements IMountPoint {
protected $storage = null;
protected $class;
protected $storageId;
+ protected $numericStorageId = null;
protected $rootId = null;
/**
@@ -211,7 +212,10 @@ class MountPoint implements IMountPoint {
* @return int
*/
public function getNumericStorageId() {
- return $this->getStorage()->getStorageCache()->getNumericId();
+ if (is_null($this->numericStorageId)) {
+ $this->numericStorageId = $this->getStorage()->getStorageCache()->getNumericId();
+ }
+ return $this->numericStorageId;
}
/**