mirror of
https://github.com/FranP-code/Baileys.git
synced 2025-10-13 00:32:22 +00:00
chore: only buffer if logged in
This commit is contained in:
@@ -533,8 +533,12 @@ export const makeSocket = ({
|
|||||||
})
|
})
|
||||||
|
|
||||||
process.nextTick(() => {
|
process.nextTick(() => {
|
||||||
// start buffering important events
|
if(creds.me?.id) {
|
||||||
ev.buffer()
|
// start buffering important events
|
||||||
|
// if we're logged in
|
||||||
|
ev.buffer()
|
||||||
|
}
|
||||||
|
|
||||||
ev.emit('connection.update', { connection: 'connecting', receivedPendingNotifications: false, qr: undefined })
|
ev.emit('connection.update', { connection: 'connecting', receivedPendingNotifications: false, qr: undefined })
|
||||||
})
|
})
|
||||||
// update credentials when required
|
// update credentials when required
|
||||||
|
|||||||
Reference in New Issue
Block a user