diff --git a/lib/Mount/GroupFolderStorage.php b/lib/Mount/GroupFolderStorage.php index b9923138e..c8ca119fb 100644 --- a/lib/Mount/GroupFolderStorage.php +++ b/lib/Mount/GroupFolderStorage.php @@ -39,12 +39,16 @@ public function getFolderId(): int { } public function getOwner(string $path): string|false { + if ($this->mountOwner !== null) { + return $this->mountOwner->getUID(); + } + $user = $this->userSession->getUser(); if ($user !== null) { return $user->getUID(); } - return $this->mountOwner !== null ? $this->mountOwner->getUID() : false; + return false; } /**