Skip to content

Commit

Permalink
feat: origin update
Browse files Browse the repository at this point in the history
  • Loading branch information
OnlyNico43 committed Oct 31, 2024
1 parent 13bb620 commit 6e539b4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cors.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ func CorsMiddleware(config Config) gin.HandlerFunc {
}

// Headers for all requests
c.Writer.Header().Set("Access-Control-Allow-Origin", strings.Join(config.AllowedOrigins, ", "))
c.Writer.Header().Set("Access-Control-Allow-Origin", currentOrigin)
c.Writer.Header().Set("Access-Control-Allow-Credentials", strconv.FormatBool(config.AllowCredentials))
c.Writer.Header().Set("Access-Control-Expose-Headers", strings.Join(config.ExposeHeaders, ", "))

Expand Down

0 comments on commit 6e539b4

Please sign in to comment.