forked from Silverfish/proton-bridge
feat: retry client auth delete while api is unreachable
This commit is contained in:
@ -141,8 +141,8 @@ func (cm *ClientManager) LogoutClient(userID string) {
|
|||||||
|
|
||||||
go func() {
|
go func() {
|
||||||
if !strings.HasPrefix(userID, "anonymous-") {
|
if !strings.HasPrefix(userID, "anonymous-") {
|
||||||
if err := client.DeleteAuth(); err != nil {
|
for client.DeleteAuth() == ErrAPINotReachable {
|
||||||
// TODO: Retry if the request failed.
|
cm.log.Warn("Logging out client failed because API was not reachable, retrying...")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
client.ClearData()
|
client.ClearData()
|
||||||
|
|||||||
Reference in New Issue
Block a user