Merge pull request #25274 from nextcloud/fix/19647/federated_users_are_not_valid_users

Do not obtain userFolder of a federated user
This commit is contained in:
Roeland Jago Douma 2021-01-22 14:36:20 +01:00 committed by GitHub
commit 4c10b59404
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -135,7 +135,7 @@ class Storage extends Wrapper {
// check if there is a app which want to disable the trash bin for this file
$fileId = $this->storage->getCache()->getId($path);
$owner = $this->storage->getOwner($path);
if ($owner === false) {
if ($owner === false || $this->storage->instanceOfStorage(\OCA\Files_Sharing\External\Storage::class)) {
$nodes = $this->rootFolder->getById($fileId);
} else {
$nodes = $this->rootFolder->getUserFolder($owner)->getById($fileId);