prevent writing response to websocket connections (#457)

This commit is contained in:
UUBulb
2024-10-25 21:45:05 +08:00
committed by GitHub
parent d086e98711
commit 380973a200
4 changed files with 33 additions and 8 deletions

View File

@@ -51,7 +51,7 @@ func serverStream(c *gin.Context) (any, error) {
}
time.Sleep(time.Second * 2)
}
return nil, nil
return nil, newWsError("")
}
var requestGroup singleflight.Group