Fix: add PATCH for CORS

This commit is contained in:
gVisor bot 2018-12-06 10:54:45 +08:00
parent 57176b410d
commit e95547bef1

View file

@ -36,7 +36,7 @@ func Start(addr string, secret string) {
cors := cors.New(cors.Options{ cors := cors.New(cors.Options{
AllowedOrigins: []string{"*"}, AllowedOrigins: []string{"*"},
AllowedMethods: []string{"GET", "POST", "PUT", "DELETE", "OPTIONS"}, AllowedMethods: []string{"GET", "POST", "PUT", "PATCH", "DELETE", "OPTIONS"},
AllowedHeaders: []string{"Content-Type", "Authorization"}, AllowedHeaders: []string{"Content-Type", "Authorization"},
MaxAge: 300, MaxAge: 300,
}) })