Add a warning to make people aware of what they should do about the 'Restart Required' message. (#1329)

This commit is contained in:
Deniz
2022-03-08 09:29:40 +01:00
committed by GitHub
parent 2e61d04d68
commit a0e97458c6

View File

@@ -480,6 +480,9 @@ export const makeSocket = ({
ev.emit('connection.update', { isNewLogin: true, qr: undefined })
end(new Boom('Restart Required', { statusCode: DisconnectReason.restartRequired }))
logger.warn('If your process stalls here, make sure to implement the reconnect logic as shown in ' +
'https://github.com/adiwajshing/Baileys/blob/master/Example/example.ts#:~:text=reconnect')
} catch(error) {
logger.info({ trace: error.stack }, 'error in pairing')
end(error)