aboutsummaryrefslogtreecommitdiffstats
path: root/modules/setting/cors.go
diff options
context:
space:
mode:
authorTamal Saha <tamal@appscode.com>2019-08-23 09:40:30 -0700
committertechknowlogick <techknowlogick@gitea.io>2019-08-23 12:40:29 -0400
commit171b3598778a1ecd0a921c71ed6755bfef68f7f0 (patch)
tree02857629ef9e8e26ee0ee559153f803f77b588b7 /modules/setting/cors.go
parentca6fb004ac50fc924861112403895d637c6a2d1d (diff)
downloadgitea-171b3598778a1ecd0a921c71ed6755bfef68f7f0.tar.gz
gitea-171b3598778a1ecd0a921c71ed6755bfef68f7f0.zip
Use gitea forked macaron (#7933)
Signed-off-by: Tamal Saha <tamal@appscode.com>
Diffstat (limited to 'modules/setting/cors.go')
-rw-r--r--modules/setting/cors.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/setting/cors.go b/modules/setting/cors.go
index c1c3bfb813..04f3120536 100644
--- a/modules/setting/cors.go
+++ b/modules/setting/cors.go
@@ -9,7 +9,7 @@ import (
"code.gitea.io/gitea/modules/log"
- "github.com/go-macaron/cors"
+ "gitea.com/macaron/cors"
)
var (
@@ -28,7 +28,7 @@ func newCORSService() {
CORSConfig = cors.Options{
Scheme: sec.Key("SCHEME").String(),
- AllowDomain: sec.Key("ALLOW_DOMAIN").String(),
+ AllowDomain: sec.Key("ALLOW_DOMAIN").Strings(","),
AllowSubdomain: sec.Key("ALLOW_SUBDOMAIN").MustBool(),
Methods: sec.Key("METHODS").Strings(","),
MaxAgeSeconds: int(maxAge.Seconds()),