Blocking/Unblocking improvements for message requests
This commit is contained in:
parent
91ea69133b
commit
9eeb68a9a7
5 changed files with 33 additions and 73 deletions
|
@ -2101,18 +2101,10 @@
|
|||
}
|
||||
|
||||
if (typeof details.blocked !== 'undefined') {
|
||||
const e164 = conversation.get('e164');
|
||||
if (details.blocked && e164) {
|
||||
storage.addBlockedNumber(e164);
|
||||
if (details.blocked) {
|
||||
conversation.block();
|
||||
} else {
|
||||
storage.removeBlockedNumber(e164);
|
||||
}
|
||||
|
||||
const uuid = conversation.get('uuid');
|
||||
if (details.blocked && uuid) {
|
||||
storage.addBlockedUuid(uuid);
|
||||
} else {
|
||||
storage.removeBlockedUuid(uuid);
|
||||
conversation.unblock();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2233,9 +2225,9 @@
|
|||
}
|
||||
|
||||
if (details.blocked) {
|
||||
storage.addBlockedGroup(id);
|
||||
conversation.block();
|
||||
} else {
|
||||
storage.removeBlockedGroup(id);
|
||||
conversation.unblock();
|
||||
}
|
||||
|
||||
conversation.set(updates);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue