Merge pull request #6946 from nextcloud/12-6574
[stable12] Fix undefined offset warning when using '/' as external storage root
This commit is contained in:
commit
aab0c3f18e
|
@ -39,7 +39,7 @@ class Api {
|
||||||
private static function formatMount($mountPoint, $mountConfig) {
|
private static function formatMount($mountPoint, $mountConfig) {
|
||||||
// strip "/$user/files" from mount point
|
// strip "/$user/files" from mount point
|
||||||
$mountPoint = explode('/', trim($mountPoint, '/'), 3);
|
$mountPoint = explode('/', trim($mountPoint, '/'), 3);
|
||||||
$mountPoint = $mountPoint[2];
|
$mountPoint = isset($mountPoint[2]) ? $mountPoint[2] : '';
|
||||||
|
|
||||||
// split path from mount point
|
// split path from mount point
|
||||||
$path = dirname($mountPoint);
|
$path = dirname($mountPoint);
|
||||||
|
|
Loading…
Reference in New Issue