allow cors from loopback addresses in debug mode (#9)

This commit is contained in:
UUBulb
2024-11-18 13:26:41 +08:00
committed by GitHub
parent 8eec79d54f
commit be79b11e58
4 changed files with 43 additions and 6 deletions

View File

@@ -121,6 +121,7 @@ func main() {
grpcHandler := rpc.ServeRPC()
httpHandler := controller.ServeWeb()
controller.InitUpgrader()
muxHandler := newHTTPandGRPCMux(httpHandler, grpcHandler)
http2Server := &http2.Server{}