1
0
mirror of https://gitlab.com/comunic/comunicapiv3 synced 2025-06-21 00:45:18 +00:00

Propagate an event when deleting a conversation

This commit is contained in:
2021-03-13 12:22:35 +01:00
parent 4776207ce8
commit 0d8a514392
3 changed files with 26 additions and 0 deletions

View File

@ -453,6 +453,9 @@ pub fn delete_conversation(conv: &Conversation) -> ResultBoxError<()> {
.cond_conv_id("id", conv.id)
.exec()?;
// Propagate information
events_helper::propagate_event(&Event::DeletedConversation(conv.id))?;
Ok(())
}

View File

@ -44,6 +44,9 @@ pub enum Event<'a> {
/// Removed a user from a conversation
RemovedUserFromConversation(&'a UserID, ConvID),
/// Delete a conversation
DeletedConversation(ConvID),
/// Created a new comment
NewComment(&'a Comment),