-
Notifications
You must be signed in to change notification settings - Fork 0
feat: expose hooks for removing project members and listening to role changes #134
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
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
RangerMauve
left a comment
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.
Small comments else LGTM
ErikSin
left a comment
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.
Code looks straight forward and works if we are following the same pattern as the invite listener!
Integrates
@comapeo/core@5.1.1.5.1.0introduces APIs related to removing project members and emitting events for when your own role changes.This PR introduces the following:
useRemoveMember()to remove a project memberuseSetUpProjectOwnRoleChangeListener()to make sure that read hooks that are affected by the emitted role change events happening in the background are invalidated.I'm a little bit unsure about the need for the listener hook, but I figured it would be similar to the invites listener hook we use.