updated gcConnOnError func
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
5858b1398f
commit
d7fcd209a4
@ -44,10 +44,8 @@ func welcomeAgents(ws *websocket.Conn, welcome wsWelcome, t string) {
|
||||
|
||||
func gcConnOnError(ws *websocket.Conn) (err error) {
|
||||
listeners.Range(func(index, value interface{}) bool {
|
||||
if value.(*connectionInfo).ConnectionPS == ws {
|
||||
if value.(*connectionInfo).ConnectionPS == ws || value.(*connectionInfo).ConnectionRR == ws {
|
||||
value.(*connectionInfo).ConnectionPS.Close()
|
||||
listeners.Delete(index)
|
||||
} else if value.(*connectionInfo).ConnectionRR == ws {
|
||||
value.(*connectionInfo).ConnectionRR.Close()
|
||||
listeners.Delete(index)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user