-
Notifications
You must be signed in to change notification settings - Fork 76
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
Allow deleting channel members and changing role of existing members #495
Conversation
quetz/main.py
Outdated
status_code=status.HTTP_409_CONFLICT, | ||
detail=f"Member {new_member.username} in {channel.name} exists", | ||
status_code=status.HTTP_404_NOT_FOUND, | ||
detail=f"channel member {username}/{channel.name} not found", |
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.
Maybe it would be clearer to write "User {username} does not exist or is not a member of {channel.name}" or something along those lines?
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.
Sure! I'll go ahead and adjust it. In fact, I can add a separate check to determine whether the user exists.
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.
should be good now
This looks good to me. Let me know what you think about my comment. Are you OK if I squash the commits when merging? Or do you want to clean up the history? |
Great!
I've incorporated your comment.
Totally fine with squashing. Sorry about the commit mess, I think I was debugging against CI at some point. |
I'll merge after CI passes! |
Nice! Apparently, there are some more CI issues, which also seem to occur on Should be unrelated to this PR then, right? |
Closes #494
post_channel_member
function to work for new and already existing channel members.delete_channel_member
function and added to REST API.None
inrest_models.Member
class (this can otherwise cause nasty internal server errors when listing channel members withNone
as role).CI running here. I believe the test failure is unrelated to these changes.