Skip to content

Commit

Permalink
允许 timestamp 头部 (#58)
Browse files Browse the repository at this point in the history
  • Loading branch information
flycash authored Mar 29, 2024
1 parent a4ec337 commit c0d7445
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ioc/gin.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ func initGinxServer(sp session.Provider,
res.Use(cors.New(cors.Config{
ExposeHeaders: []string{"X-Refresh-Token", "X-Access-Token"},
AllowCredentials: true,
AllowHeaders: []string{"Authorization", "Content-Type"},
AllowHeaders: []string{"X-Timestamp", "Authorization", "Content-Type"},
AllowOriginFunc: func(origin string) bool {
if strings.HasPrefix(origin, "http://localhost") {
return true
Expand Down

0 comments on commit c0d7445

Please sign in to comment.