diff --git a/genStr b/genStr index 5121513b3..08e559f61 100644 --- a/genStr +++ b/genStr @@ -8,4 +8,4 @@ # # All rights reserved. -python3 tools/genStrSession.py +exec python3 tools/genStrSession.py diff --git a/init/checks.sh b/init/checks.sh index 1b15c14be..6d7d6d47f 100644 --- a/init/checks.sh +++ b/init/checks.sh @@ -53,6 +53,7 @@ _checkDefaultVars() { [UPSTREAM_REMOTE]="upstream" [UPSTREAM_REPO]="https://github.com/UsergeTeam/Userge" [LOAD_UNOFFICIAL_PLUGINS]=false + [ASSERT_SINGLE_INSTANCE]=false [CUSTOM_PLUGINS_REPO]="" [G_DRIVE_IS_TD]=true [CMD_TRIGGER]="." @@ -83,7 +84,7 @@ except Exception as e: print(e)') [[ $herokuErr ]] && quit "heroku response > $herokuErr" fi - for var in G_DRIVE_IS_TD LOAD_UNOFFICIAL_PLUGINS; do + for var in G_DRIVE_IS_TD LOAD_UNOFFICIAL_PLUGINS ASSERT_SINGLE_INSTANCE; do eval $var=$(tr "[:upper:]" "[:lower:]" <<< ${!var}) done local uNameAndPass=$(grep -oP "(?<=\/\/)(.+)(?=\@cluster)" <<< $DATABASE_URL) diff --git a/userge/config.py b/userge/config.py index e1a791eb2..754cdd0f7 100644 --- a/userge/config.py +++ b/userge/config.py @@ -66,7 +66,7 @@ class Config: HEROKU_APP_NAME = os.environ.get("HEROKU_APP_NAME") G_DRIVE_IS_TD = os.environ.get("G_DRIVE_IS_TD") == "true" LOAD_UNOFFICIAL_PLUGINS = os.environ.get("LOAD_UNOFFICIAL_PLUGINS") == "true" - ASSERT_SINGLE_INSTANCE = os.environ.get("ASSERT_SINGLE_INSTANCE", "false").lower() == "true" + ASSERT_SINGLE_INSTANCE = os.environ.get("ASSERT_SINGLE_INSTANCE") == "true" THUMB_PATH = DOWN_PATH + "thumb_image.jpg" TMP_PATH = "userge/plugins/temp/" MAX_MESSAGE_LENGTH = 4096