Skip to content

Commit

Permalink
PLAT-25776 Do a full reconnect on WA 418 errors (#80)
Browse files Browse the repository at this point in the history
  • Loading branch information
Fizzadar authored Jul 16, 2024
1 parent 34fb1de commit ef6f441
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions user.go
Original file line number Diff line number Diff line change
Expand Up @@ -1063,6 +1063,11 @@ func (user *User) e2eeEventHandler(rawEvt any) {
}
user.log.Debug().Msg("Reconnecting e2ee client after WhatsApp 415 error")
go user.connectE2EE()
} else if e.Reason == events.ConnectFailureReason(418) {
// TODO: what is error 418?
user.resetWADevice()
user.log.Debug().Msg("Doing full reconnect after WhatsApp 418 error")
go user.FullReconnect()
}
}

Expand Down

0 comments on commit ef6f441

Please sign in to comment.