diff --git a/arknights_mower/utils/config/__init__.py b/arknights_mower/utils/config/__init__.py index d6ffabea..0220f759 100644 --- a/arknights_mower/utils/config/__init__.py +++ b/arknights_mower/utils/config/__init__.py @@ -26,7 +26,6 @@ def save(): def load(): global conf if not conf_path.is_file(): - conf_path.parent.mkdir(exist_ok=True) conf = Conf() save() with conf_path.open("r", encoding="utf-8") as f: diff --git a/webview_ui.py b/webview_ui.py index 0371bece..b403277b 100755 --- a/webview_ui.py +++ b/webview_ui.py @@ -192,11 +192,13 @@ def recv_msg(): import sys - from arknights_mower.utils import config, path + from arknights_mower.utils import path if len(sys.argv) == 2: path.global_space = sys.argv[1] + from arknights_mower.utils import config + conf = config.conf tray = conf.webview.tray token = conf.webview.token