Skip to content
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

Backport #5761 to 3.x #5763

Merged
merged 4 commits into from
Jun 30, 2022
Merged

Backport #5761 to 3.x #5763

merged 4 commits into from
Jun 30, 2022

Conversation

marrus-sh
Copy link
Collaborator

See #5761 for discussion.

tamsin johnson and others added 4 commits June 29, 2022 15:22
knowledge about how the ACL keys are handled for Groups is spread throughout the
codebase. treating this information as an attribute on the group seems cleaner.

`Hyrax::Group#user_key` is provided for easy compatibility with `::User`.
Also fixes an incorrect implementation of `Hyrax::Group.from_key`.

The Sipity specs were inspired by the similar specs for `Hyrax::User`.
These methods help reduce the amount of knowledge that ACLs require
regarding agents.

For Users, the default implementation is just to use `#user_key` and
`User.find_by_user_key`.

(An alternate approach would be just to implement `#user_key` and
`.find_by_user_key` directly on `Hyrax::Group`, but I’m not sure we
want Groups to be treatable as Users in all contexts where `#user_key`
might be used.)
@no-reply no-reply merged commit abfda2f into 3.x-stable Jun 30, 2022
@no-reply no-reply deleted the backport-5761 branch June 30, 2022 17:43
@dlpierce dlpierce added the notes-minor Release Notes: Non-breaking features label Aug 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
notes-minor Release Notes: Non-breaking features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants