Closed javiercr closed 3 months ago
When a user log outs the device from the Messenger mobile app for e2e chats, whatsmeow dispatches a events.LoggedOut event rather than a events.ConnectFailure:
events.LoggedOut
events.ConnectFailure
case code == "401" && conflictType == "device_removed": cli.expectDisconnect() cli.Log.Infof("Got device removed stream error, sending LoggedOut event and deleting session") go cli.dispatchEvent(&events.LoggedOut{OnConnect: false, Reason: events.ConnectFailureLoggedOut}) //...
https://github.com/tulir/whatsmeow/blob/main/connectionevents.go#L34-L37
This PR fixes that, so even if the device is removed for e2e chats, we keep the bridge connected to the WA socket.
When a user log outs the device from the Messenger mobile app for e2e chats, whatsmeow dispatches a
events.LoggedOut
event rather than aevents.ConnectFailure
:https://github.com/tulir/whatsmeow/blob/main/connectionevents.go#L34-L37
This PR fixes that, so even if the device is removed for e2e chats, we keep the bridge connected to the WA socket.