From: Christoph Gysin Date: Mon, 13 Nov 2017 14:49:04 +0000 (+0200) Subject: remove duplication X-Git-Tag: 1.3~6^2~3 X-Git-Url: https://git.donarmstrong.com/?p=deb_pkgs%2Fautorandr.git;a=commitdiff_plain;h=727512737822e2f629290d90150408c7c726b9fb remove duplication --- diff --git a/autorandr.py b/autorandr.py index e5ab42f..756e76d 100755 --- a/autorandr.py +++ b/autorandr.py @@ -802,11 +802,9 @@ def exec_scripts(profile_path, script_name, meta_information=None): Returns True unless any of the scripts exited with non-zero exit status. """ all_ok = True + env = os.environ.copy() if meta_information: - env = os.environ.copy() env.update({"AUTORANDR_%s" % str(key).upper(): str(value) for (key, value) in meta_information.items()}) - else: - env = os.environ.copy() # If there are multiple candidates, the XDG spec tells to only use the first one. ran_scripts = set()