Update client/ayon_core/hooks/pre_remove_launcher_paths.py

Co-authored-by: Jakub Trllo <43494761+iLLiCiTiT@users.noreply.github.com>
This commit is contained in:
Ondřej Samohel 2025-04-30 19:07:30 +02:00 committed by GitHub
parent 1f48b1568d
commit edabad6c13
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -22,11 +22,7 @@ class PreRemoveLauncherPaths(PreLaunchHook):
def execute(self):
# Remove launcher paths from the system
paths = []
try:
ayon_root = os.path.normpath(self.launch_context.env["AYON_ROOT"])
except KeyError:
self.log.warning("AYON_ROOT not found in environment variables.")
return
ayon_root = os.path.normpath(os.environ["AYON_ROOT"])
paths.extend(
path