mirror of
https://github.com/chatmail/core.git
synced 2026-05-22 08:16:32 +03:00
Remove obsolete ChatId::is_unset check
The chat::lookup_by_contact_id call is already resultified, the database can not contain this since the auto-increment counter is bumped to 7 by the time the database tables are created.
This commit is contained in:
@@ -704,14 +704,12 @@ impl Job {
|
|||||||
match chat.typ {
|
match chat.typ {
|
||||||
Chattype::Group | Chattype::Mailinglist => {
|
Chattype::Group | Chattype::Mailinglist => {
|
||||||
// The next lines are actually what we do in
|
// The next lines are actually what we do in
|
||||||
let (test_normal_chat_id, test_normal_chat_id_blocked) =
|
let (_test_normal_chat_id, test_normal_chat_id_blocked) =
|
||||||
chat::lookup_by_contact_id(context, msg.from_id)
|
chat::lookup_by_contact_id(context, msg.from_id)
|
||||||
.await
|
.await
|
||||||
.unwrap_or_default();
|
.unwrap_or_default();
|
||||||
|
|
||||||
if !test_normal_chat_id.is_unset()
|
if test_normal_chat_id_blocked == Blocked::Not {
|
||||||
&& test_normal_chat_id_blocked == Blocked::Not
|
|
||||||
{
|
|
||||||
chat.id.unblock(context).await;
|
chat.id.unblock(context).await;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user