From 07bc1b8257f4a83092dc2de8aac6dd057cf4b39e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moritz=20Br=C3=BCckner?= Date: Thu, 26 Sep 2019 16:46:18 +0200 Subject: [PATCH] Fix open_folder() Project folder was opened twice on windows and mac --- blender/arm/utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/blender/arm/utils.py b/blender/arm/utils.py index 8fbd262e..ad519cfd 100755 --- a/blender/arm/utils.py +++ b/blender/arm/utils.py @@ -582,11 +582,11 @@ def open_editor(hx_path=None): raise FileNotFoundError(f'Code editor executable not found: {ide_bin}. You can change the path in the Armory preferences.') def open_folder(): - if arm.utils.get_os() is 'win': + if arm.utils.get_os() == 'win': subprocess.Popen('explorer /select,"' + arm.utils.get_fp() + '"') - if arm.utils.get_os() is 'mac': + elif arm.utils.get_os() == 'mac': subprocess.Popen(['open', arm.utils.get_fp()]) - if arm.utils.get_os() is 'linux': + elif arm.utils.get_os() == 'linux': subprocess.Popen(['xdg-open', arm.utils.get_fp()]) else: webbrowser.open('file://' + arm.utils.get_fp())