mirror of
https://github.com/stoatchat/stoatchat.git
synced 2026-07-14 13:36:59 +00:00
Move group leave into posthandle hook.
This commit is contained in:
@@ -100,12 +100,6 @@ pub fn prehandle_hook(notification: &ClientboundNotification) {
|
||||
}
|
||||
}
|
||||
}
|
||||
ClientboundNotification::ChannelGroupLeave { id, user } => {
|
||||
get_hive()
|
||||
.hive
|
||||
.unsubscribe(&user.to_string(), &id.to_string())
|
||||
.ok();
|
||||
}
|
||||
ClientboundNotification::UserRelationship { id, user, status } => {
|
||||
if status != &RelationshipStatus::None {
|
||||
subscribe_if_exists(id.clone(), user.clone()).ok();
|
||||
@@ -128,6 +122,12 @@ pub fn posthandle_hook(notification: &ClientboundNotification) {
|
||||
.ok();
|
||||
}
|
||||
}
|
||||
ClientboundNotification::ChannelGroupLeave { id, user } => {
|
||||
get_hive()
|
||||
.hive
|
||||
.unsubscribe(&user.to_string(), &id.to_string())
|
||||
.ok();
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user