Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| b296d73367 |
@@ -294,6 +294,11 @@ func (wsClient *SafeWebsocketClient) reconnectHandler() {
|
|||||||
default: // prevent blocking if chan is full
|
default: // prevent blocking if chan is full
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if len(wsClient.reconnectChans) > 1 {
|
||||||
|
wsClient.reconnectChans = wsClient.reconnectChans[1:]
|
||||||
|
} else {
|
||||||
|
wsClient.reconnectChans = nil
|
||||||
|
}
|
||||||
}
|
}
|
||||||
case <-wsClient.ctx.Done():
|
case <-wsClient.ctx.Done():
|
||||||
log.Println("reconnect handler stopped due to client shutdown")
|
log.Println("reconnect handler stopped due to client shutdown")
|
||||||
|
|||||||
Reference in New Issue
Block a user