diff --git a/auth/auth.go b/auth/auth.go index 842961945..cd4db11e8 100644 --- a/auth/auth.go +++ b/auth/auth.go @@ -177,7 +177,7 @@ func AdminCheck(pubkey string) bool { } func IsFreePass() bool { - if len(config.SuperAdmins) == 1 && config.SuperAdmins[0] == config.AdminDevFreePass { + if len(config.SuperAdmins) == 1 && config.SuperAdmins[0] == config.AdminDevFreePass || config.AdminStrings == "" { return true } return false diff --git a/config/config.go b/config/config.go index 5feb3f7d9..84a37e9eb 100644 --- a/config/config.go +++ b/config/config.go @@ -34,6 +34,7 @@ var S3Url string var AdminCheck string var AdminDevFreePass = "FREE_PASS" var Connection_Auth string +var AdminStrings string var S3Client *s3.Client var PresignClient *s3.PresignClient @@ -44,7 +45,7 @@ func InitConfig() { RelayUrl = os.Getenv("RELAY_URL") MemeUrl = os.Getenv("MEME_URL") RelayAuthKey = os.Getenv("RELAY_AUTH_KEY") - AdminStrings := os.Getenv("ADMINS") + AdminStrings = os.Getenv("ADMINS") AwsSecret := os.Getenv("AWS_SECRET_ACCESS") AwsAccess := os.Getenv("AWS_ACCESS_KEY_ID") AwsRegion := os.Getenv("AWS_REGION")