From 85738c10655b747cbcd771e490922bc7c699ba61 Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Tue, 19 Mar 2024 15:45:02 -0400 Subject: [PATCH] refactor: replace AllowedOrigins with AllowOriginFunc --- api/account/account.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/api/account/account.go b/api/account/account.go index a12ed9c..423c815 100644 --- a/api/account/account.go +++ b/api/account/account.go @@ -413,7 +413,9 @@ func (a *AccountAPI) Routes() (*httprouter.Router, error) { } corsMw := cors.New(cors.Options{ - AllowedOrigins: []string{"*." + a.config.Config().Core.Domain}, + AllowOriginFunc: func(origin string) bool { + return true + }, AllowedMethods: []string{"*"}, })