diff --git a/src/chat.rs b/src/chat.rs
index 40388fc92..fc26c606e 100644
--- a/src/chat.rs
+++ b/src/chat.rs
@@ -39,7 +39,7 @@ use crate::receive_imf::ReceivedMsg;
use crate::smtp::send_msg_to_smtp;
use crate::sql;
use crate::stock_str;
-use crate::sync::{self, ChatAction, Sync::*, SyncData};
+use crate::sync::{self, Sync::*, SyncData};
use crate::tools::{
buf_compress, create_id, create_outgoing_rfc724_mid, create_smeared_timestamp,
create_smeared_timestamps, get_abs_path, gm2local_offset, improve_single_line_input,
@@ -400,7 +400,7 @@ impl ChatId {
if sync.into() {
// NB: For a 1:1 chat this currently triggers `Contact::block()` on other devices.
- chat.sync(context, ChatAction::Block)
+ chat.sync(context, SyncAction::Block)
.await
.log_err(context)
.ok();
@@ -421,7 +421,7 @@ impl ChatId {
// TODO: For a 1:1 chat this currently triggers `Contact::unblock()` on other devices.
// Maybe we should unblock the contact locally too, this would also resolve discrepancy
// with `block()` which also blocks the contact.
- chat.sync(context, ChatAction::Unblock)
+ chat.sync(context, SyncAction::Unblock)
.await
.log_err(context)
.ok();
@@ -472,7 +472,7 @@ impl ChatId {
}
if sync.into() {
- chat.sync(context, ChatAction::Accept)
+ chat.sync(context, SyncAction::Accept)
.await
.log_err(context)
.ok();
@@ -637,7 +637,7 @@ impl ChatId {
if sync.into() {
let chat = Chat::load_from_db(context, self).await?;
- chat.sync(context, ChatAction::SetVisibility(visibility))
+ chat.sync(context, SyncAction::SetVisibility(visibility))
.await
.log_err(context)
.ok();
@@ -1932,18 +1932,18 @@ impl Chat {
Ok(msg.id)
}
- /// Sends a `ChatAction` synchronising chat contacts to other devices.
+ /// Sends a `SyncAction` synchronising chat contacts to other devices.
pub(crate) async fn sync_contacts(&self, context: &Context) -> Result<()> {
let mut addrs = Vec::new();
for contact_id in get_chat_contacts(context, self.id).await? {
let contact = Contact::get_by_id(context, contact_id).await?;
addrs.push(contact.get_addr().to_string());
}
- self.sync(context, ChatAction::SetContacts(addrs)).await
+ self.sync(context, SyncAction::SetContacts(addrs)).await
}
/// Returns chat id for the purpose of synchronisation across devices.
- async fn get_sync_id(&self, context: &Context) -> Result