mirror of
https://github.com/nextcloud/server.git
synced 2026-06-13 18:50:47 -04:00
Merge 4960ef3d4d into d02155784b
This commit is contained in:
commit
8bccfb27cb
1 changed files with 4 additions and 3 deletions
|
|
@ -447,9 +447,10 @@ class FileEventsListener implements IEventListener {
|
|||
$owner = null;
|
||||
}
|
||||
|
||||
// If no owner, extract it from the path.
|
||||
// e.g. /user/files/foobar.txt
|
||||
if (!$owner) {
|
||||
// If no owner, extract it from the path, e.g. /user/files/foobar.txt
|
||||
// Also try this if they are the same, because it might be a group folder that the user does not have access to
|
||||
// E.g. where filling in a form with a spreadsheet attached
|
||||
if (!$owner || $owner == $user) {
|
||||
$parts = explode('/', $node->getPath(), 4);
|
||||
if (count($parts) === 4) {
|
||||
$owner = $parts[1];
|
||||
|
|
|
|||
Loading…
Reference in a new issue