diff --git a/hooks/tk-multi-launchapp/before_app_launch.py b/hooks/tk-multi-launchapp/before_app_launch.py index 53f04bea6..91fb58832 100755 --- a/hooks/tk-multi-launchapp/before_app_launch.py +++ b/hooks/tk-multi-launchapp/before_app_launch.py @@ -79,8 +79,9 @@ def execute(self, app_path, app_args, version, engine_name, **kwargs): houdini_otls_template = tk.templates["houdini_otls"] otls_path = houdini_otls_template.apply_fields(current_context).replace(os.sep, '/') - # Check if HOUDINI_OTLDSCAN_PATH exists in environment, if it's empty add the default value back - if os.environ.get("HOUDINI_OTLDSCAN_PATH") == "": + # Check if HOUDINI_OTLSCAN_PATH exists in environment, if it's empty add the default value back + HOUDINI_OTLSCAN_PATH = os.environ.get("HOUDINI_OTLSCAN_PATH") + if HOUDINI_OTLSCAN_PATH is None or HOUDINI_OTLSCAN_PATH == "": sgtk.util.append_path_to_env_var("HOUDINI_OTLSCAN_PATH", "@/otls") # Add the project otls path to the environment