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

Fix panic when deleting a user or group that does not exist #3218

Merged
merged 5 commits into from
Mar 27, 2019

Conversation

gitlw
Copy link

@gitlw gitlw commented Mar 27, 2019

When deleting a user or group that does not exist, the return variable of type AclEntity has a type, with a value of nil. In such a case, the variable is treated not being nil per https://golang.org/doc/faq#nil_error


This change is Reviewable

@gitlw gitlw requested a review from mangalaman93 March 27, 2019 18:31
Copy link
Contributor

@manishrjain manishrjain left a comment

Choose a reason for hiding this comment

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

Depend on the interface function to determine if you have a valid entity or not.

Reviewable status: 0 of 1 files reviewed, all discussions resolved (waiting on @mangalaman93)

Copy link
Contributor

@manishrjain manishrjain left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 2 of 2 files at r1.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

@gitlw gitlw merged commit 288827e into master Mar 27, 2019
@gitlw gitlw deleted the gitlw/fix_acl_nil_pointer_check branch March 27, 2019 21:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants