added allow creds

This commit is contained in:
ACoolName 2024-05-25 01:28:18 +03:00
parent 37bf73f336
commit e448a6c2f8

View File

@ -22,6 +22,7 @@ func main() {
router := gin.Default()
cors_config := cors.DefaultConfig()
cors_config.AllowOrigins = []string{"https://games.acooldomain.co"}
cors_config.AllowCredentials = true
router.Use(cors.New(cors_config))
file, err := os.Open(os.Getenv(CONFIG_PATH_ENV_VAR))
if err != nil {