Skip to content
Snippets Groups Projects
Unverified Commit 58d24b7e authored by Morris Jobke's avatar Morris Jobke Committed by GitHub
Browse files

Merge pull request #23606 from nextcloud/bugfix/22913/only-use-index-when-it-exists

Only use index of mount point when it is there
parents 38bb40cf c1834bac
No related branches found
No related tags found
No related merge requests found
......@@ -545,7 +545,11 @@ class OC_Helper {
if ($owner) {
$ownerDisplayName = $owner->getDisplayName();
}
[,,,$mountPoint] = explode('/', $mount->getMountPoint(), 4);
if (substr_count($mount->getMountPoint(), '/') < 3) {
$mountPoint = '';
} else {
[,,,$mountPoint] = explode('/', $mount->getMountPoint(), 4);
}
return [
'free' => $free,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment