diff options
author | Robin Appelman <robin@icewind.nl> | 2022-02-23 20:11:46 +0300 |
---|---|---|
committer | Robin Appelman <robin@icewind.nl> | 2022-03-04 18:29:50 +0300 |
commit | 5c0fe934988960ece3ac71d5a1dfc8df405413aa (patch) | |
tree | a4b4cded5a1876ba58651f87a385df16c2460f63 /lib/private/Files/View.php | |
parent | 15ff65c12fafbe1c4026fa6f734fb58fdbdcda11 (diff) |
move teardown logic to SetupManager
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'lib/private/Files/View.php')
-rw-r--r-- | lib/private/Files/View.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/private/Files/View.php b/lib/private/Files/View.php index 3cdc6166840..6f96f911785 100644 --- a/lib/private/Files/View.php +++ b/lib/private/Files/View.php @@ -1739,12 +1739,13 @@ class View { $manager = Filesystem::getMountManager(); $mounts = $manager->findIn($this->fakeRoot); $mounts[] = $manager->find($this->fakeRoot); - // reverse the array so we start with the storage this view is in + $mounts = array_filter($mounts); + // reverse the array, so we start with the storage this view is in // which is the most likely to contain the file we're looking for $mounts = array_reverse($mounts); - // put non shared mounts in front of the shared mount - // this prevent unneeded recursion into shares + // put non-shared mounts in front of the shared mount + // this prevents unneeded recursion into shares usort($mounts, function (IMountPoint $a, IMountPoint $b) { return $a instanceof SharedMount && (!$b instanceof SharedMount) ? 1 : -1; }); |