diff --git a/src/Socket/socket.ts b/src/Socket/socket.ts index a3b4f1d..45323d7 100644 --- a/src/Socket/socket.ts +++ b/src/Socket/socket.ts @@ -524,6 +524,11 @@ export const makeSocket = ({ const reason = +(node.attrs.reason || 500) end(new Boom('Connection Failure', { statusCode: reason, data: node.attrs })) }) + + ws.on('CB:ib,,downgrade_webclient', () => { + end(new Boom('Multi-device beta not joined', { statusCode: DisconnectReason.notJoinedBeta })) + }) + process.nextTick(() => { ev.emit('connection.update', { connection: 'connecting', receivedPendingNotifications: false, qr: undefined }) }) diff --git a/src/Types/index.ts b/src/Types/index.ts index 1c69c2d..6eca814 100644 --- a/src/Types/index.ts +++ b/src/Types/index.ts @@ -60,7 +60,8 @@ export enum DisconnectReason { timedOut = 408, loggedOut = 401, badSession = 500, - restartRequired = 410 + restartRequired = 410, + notJoinedBeta = 403 } export type WAInitResponse = {