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

Get role resources #147

Merged
merged 3 commits into from
Jul 24, 2023
Merged

Get role resources #147

merged 3 commits into from
Jul 24, 2023

Conversation

mikemrm
Copy link
Contributor

@mikemrm mikemrm commented Jul 24, 2023

Adds endpoints to retrieve a role as well as retrieve a roles resource assignment.

@mikemrm mikemrm marked this pull request as ready for review July 24, 2023 19:57
@mikemrm mikemrm requested review from a team as code owners July 24, 2023 19:57
Comment on lines 594 to 596
if len(resActions) > 1 {
e.logger.Warnw("role is assigned to more than one resource", "role.id", roleResource.ID.String())
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO it'd probably be better for us to return an error here, since this is something that shouldn't happen.

Comment on lines 632 to 634
if len(resActions) > 1 {
e.logger.Warnw("role is assigned to more than one resource", "role.id", roleResource.ID.String())
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above.

@mikemrm mikemrm merged commit 7364ba4 into infratographer:main Jul 24, 2023
@mikemrm mikemrm deleted the get-role-resources branch July 24, 2023 22:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants