Browse Source

fix checked .env file

Alex Sidorov 1 year ago
parent
commit
fdeb5293a0
1 changed files with 3 additions and 1 deletions
  1. 3 1
      init_var.py

+ 3 - 1
init_var.py

@@ -1,5 +1,5 @@
 import os
-import os
+import sys
 import appdirs
 from dotenv import load_dotenv
 from window.DialogCustomVariables import DialogCustomVariables
@@ -25,5 +25,7 @@ def load_variables():
 
     if not os.path.exists(dotenv_path):
         DialogCustomVariables(dotenv_path).exec_()
+        if not os.path.exists(dotenv_path):
+            sys.exit()
     
     load_dotenv(dotenv_path=dotenv_path)