Skip to content

Commit b7c935c

Browse files
committed
feat: allowed localhost
1 parent 1edcedd commit b7c935c

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

cmd/serve_http.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,11 @@ var serveHttpCmd = &cobra.Command{
3737

3838
// route
3939
router := registerHandler(app)
40+
// router.Use(cors.Default().Handler)
4041

4142
// build cors
4243
muxCorsWithRouter := cors.New(cors.Options{
43-
AllowedOrigins: []string{"*"},
44+
AllowedOrigins: []string{"*", "http://localhost:8000"},
4445
AllowedMethods: []string{"*"},
4546
AllowedHeaders: []string{"*"},
4647
}).Handler(router)

0 commit comments

Comments
 (0)