Skip to content

Commit

Permalink
Allow multiple allowed origons to be set
Browse files Browse the repository at this point in the history
Git ignore intellij files
  • Loading branch information
nielses committed May 7, 2023
1 parent f5016b5 commit 9bc01fb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,6 @@ src/wwwroot
# Runtime data
keys
tempkey.jwk

#Intellij
.idea
2 changes: 1 addition & 1 deletion src/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
var corsOptions = Config.GetServerCorsAllowedOrigins();

app.UseCors(builder => builder
.WithOrigins(corsOptions.First())
.WithOrigins(corsOptions.ToArray())
.AllowAnyMethod()
.AllowAnyHeader()
.AllowCredentials());
Expand Down

0 comments on commit 9bc01fb

Please sign in to comment.