mirror of
https://github.com/cheveguerra/whatsapp-web.js.git
synced 2026-04-19 20:19:14 +00:00
fix: message.delete() can revoke for everyone (#1107)
Change msg.canRevoke to msg._canRevoke according to WhatsApp code change
This commit is contained in:
@@ -382,7 +382,7 @@ class Message extends Base {
|
|||||||
await this.client.pupPage.evaluate((msgId, everyone) => {
|
await this.client.pupPage.evaluate((msgId, everyone) => {
|
||||||
let msg = window.Store.Msg.get(msgId);
|
let msg = window.Store.Msg.get(msgId);
|
||||||
|
|
||||||
if (everyone && msg.id.fromMe && msg.canRevoke()) {
|
if (everyone && msg.id.fromMe && msg._canRevoke()) {
|
||||||
return window.Store.Cmd.sendRevokeMsgs(msg.chat, [msg], true);
|
return window.Store.Cmd.sendRevokeMsgs(msg.chat, [msg], true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user