mirror of
https://github.com/FranP-code/Baileys.git
synced 2025-10-13 00:32:22 +00:00
fix: empty messages upsert event on history sync
This commit is contained in:
@@ -253,7 +253,9 @@ export const makeMessagesRecvSocket = (config: SocketConfig) => {
|
|||||||
messages.push(m.message!)
|
messages.push(m.message!)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ev.emit('messages.upsert', { messages, type: 'prepend' })
|
if(messages.length) {
|
||||||
|
ev.emit('messages.upsert', { messages, type: 'prepend' })
|
||||||
|
}
|
||||||
break
|
break
|
||||||
case proto.HistorySync.HistorySyncHistorySyncType.PUSH_NAME:
|
case proto.HistorySync.HistorySyncHistorySyncType.PUSH_NAME:
|
||||||
const contacts = item.pushnames.map(
|
const contacts = item.pushnames.map(
|
||||||
|
|||||||
Reference in New Issue
Block a user