-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use the correct mountpoint to calculate #21489
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lib/private/Share20/Manager.php
Outdated
if (!$isFederatedShare && $share->getNode()->getOwner() && $share->getNode()->getOwner()->getUID() !== $share->getSharedBy()) { | ||
// When it's a reshare use the parent share permissions as maximum | ||
$userMountPointId = $mount->getStorageRootId(); | ||
$userMountPoints = $userFolder->getById($userMountPointId); | ||
$userMountPoint = array_shift($userMountPoints); | ||
|
||
if ($userMountPoint === null) { | ||
throw new \Exception('Could not get proper user mount for ' . $userMountPointId . '. Failing since else the next calls are called with null'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be a GenericShareException
, or it should be documented that generalCreateChecks
can throw a plain Exception
too.
Looking into the tests now |
Tried my best but this is so … up. |
071603f
to
25c4591
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🦈 Time to fix up
If we use the owners mount point this results in null. And then the rest of the checks get called with null. Which doesn't work. Signed-off-by: Roeland Jago Douma <[email protected]>
Signed-off-by: Daniel Calviño Sánchez <[email protected]>
Signed-off-by: Robin Appelman <[email protected]>
Signed-off-by: Robin Appelman <[email protected]>
Signed-off-by: Robin Appelman <[email protected]>
25c4591
to
118965a
Compare
Backports I guess @rullzer |
Yes |
/backport to stable19 |
/backport to stable18 |
/backport to stable17 |
If we use the owners mount point this results in null. And then the rest
of the checks get called with null. Which doesn't work.
Signed-off-by: Roeland Jago Douma [email protected]