-
Notifications
You must be signed in to change notification settings - Fork 187
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
fix populating user drive and drives #5426
Conversation
Signed-off-by: Jörn Friedrich Dreyer <[email protected]>
Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes. |
Signed-off-by: Jörn Friedrich Dreyer <[email protected]>
Signed-off-by: Jörn Friedrich Dreyer <[email protected]>
💥 Acceptance test Core-API-Tests-ocis-storage-3 failed. Further test are cancelled... |
@butonic please double check this with the client platforms. |
Kudos, SonarCloud Quality Gate passed! |
clients did not report to expect problems with this |
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.
Just clarification needed. Rest looks good 👍
if d.GetDriveType() == "personal" && sp.GetOwner().GetId().GetOpaqueId() == user.GetId() { | ||
if listDrive { | ||
user.Drive = d | ||
} | ||
} else { | ||
drives = append(drives, *d) | ||
user.Drives = drives | ||
if listDrives { | ||
user.Drives = append(user.Drives, *d) | ||
} |
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.
Just for clarification: This means that personal spaces do not appear in the drives
list. I can only get them as single drive
. Is that the intended behaviour?
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.
Yes, there is always only one personal drive you are the owner of: /me/drive
As a secretary you might get access to other personal drives but they will only show up in /me/drives.
The admin might create another drive that is owned by you. I would still use type 'project' for that. We should reserve type 'personal' only for the users personal drive.
Author: Jörn Friedrich Dreyer <[email protected]> Date: Thu Jan 26 11:54:32 2023 +0100 fix populating user drive and drives (#5426) * fix populating user drive and drives Signed-off-by: Jörn Friedrich Dreyer <[email protected]> * update changelog Signed-off-by: Jörn Friedrich Dreyer <[email protected]> * fix test condition Signed-off-by: Jörn Friedrich Dreyer <[email protected]> Signed-off-by: Jörn Friedrich Dreyer <[email protected]>
continuation of #5421
The personal
drive
should not be part of thedrives
list.And when decomposedfs supports the space owner filter we should use that instead of a user + space type "personal" filter, but not part of this PR.