mirror of
https://github.com/FranP-code/Baileys.git
synced 2025-10-13 00:32:22 +00:00
fix: decrypt race condition
This commit is contained in:
@@ -524,11 +524,10 @@ export const makeMessagesRecvSocket = (config: SocketConfig) => {
|
||||
return
|
||||
}
|
||||
|
||||
const decryptionTask = decrypt()
|
||||
await Promise.all([
|
||||
processingMutex.mutex(
|
||||
async() => {
|
||||
await decryptionTask
|
||||
await decrypt()
|
||||
// message failed to decrypt
|
||||
if(msg.messageStubType === proto.WebMessageInfo.StubType.CIPHERTEXT) {
|
||||
logger.error(
|
||||
|
||||
Reference in New Issue
Block a user