main.py: Fix payload routing

This commit is contained in:
Mykola Grymalyuk
2023-05-27 10:58:16 -06:00
parent c8b6eec14f
commit 7d0bbf62bf
3 changed files with 2 additions and 3 deletions

View File

@@ -107,9 +107,6 @@ class OpenCoreLegacyPatcher:
ignore_args = ["--auto_patch", "--gui_patch", "--gui_unpatch", "--update_installed"]
if not any(x in sys.argv for x in ignore_args):
self.constants.current_path = Path.cwd()
if getattr(sys, "frozen", False) and hasattr(sys, "_MEIPASS"):
logging.info("- Rerouting payloads location")
self.constants.payload_path = sys._MEIPASS / Path("payloads")
ignore_args = ignore_args.pop(0)
if not any(x in sys.argv for x in ignore_args):

View File

@@ -316,6 +316,7 @@ class DownloadObject:
logging.error(f"- Error preparing working directory {path}: {self.error_msg}")
return False
logging.info(f"- Directory ready: {path}")
return True