Skip to content

Commit 6d6bc32

Browse files
committed
fix: Update cors config with wildcard
1 parent 00326c2 commit 6d6bc32

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/api/server.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ func InitServer() (*Server, error) {
4545
engine.RedirectTrailingSlash = false
4646
engine.RedirectFixedPath = false
4747
corscfg := cors.DefaultConfig()
48-
corscfg.AllowOrigins = []string{"http://localhost:3000", "https://cogito-ntnu.no"}
48+
corscfg.AllowOrigins = []string{"http://localhost:3000", "https://cogito-ntnu.no", "*"}
4949
corscfg.AllowMethods = []string{"GET", "POST", "PUT", "DELETE", "OPTIONS"}
5050
corscfg.AllowHeaders = []string{"Origin", "Content-Type", "Authorization"}
5151
corscfg.AllowCredentials = true

0 commit comments

Comments
 (0)