mirror of
https://github.com/nextcloud/server.git
synced 2026-06-13 18:50:47 -04:00
Merge pull request #20203 from nextcloud/backport/19978/stable17
[stable17] Actually check if the owner is not null
This commit is contained in:
commit
0d872d81f4
1 changed files with 5 additions and 0 deletions
|
|
@ -1685,6 +1685,11 @@ class View {
|
|||
if (!$info) {
|
||||
throw new NotFoundException($path . ' not found while trying to get owner');
|
||||
}
|
||||
|
||||
if ($info->getOwner() === null) {
|
||||
throw new NotFoundException($path . ' has no owner');
|
||||
}
|
||||
|
||||
return $info->getOwner()->getUID();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue