aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Tari <robert@tari.in>2022-09-13 17:11:16 +0200
committerRobert Tari <robert@tari.in>2022-09-13 17:11:16 +0200
commit9ab79eebfcb66e73cd8aa9b82a42a5e34f422aa5 (patch)
tree2e32940c6e2894e5ea95844760828d708c6fad64
parent4f23916d57d00fb5ad6a409c50ee85c6bc64f1d5 (diff)
parente268112107df9c5938037ca338b9cf6c83603025 (diff)
downloadayatana-settings-9ab79eebfcb66e73cd8aa9b82a42a5e34f422aa5.tar.gz
ayatana-settings-9ab79eebfcb66e73cd8aa9b82a42a5e34f422aa5.tar.bz2
ayatana-settings-9ab79eebfcb66e73cd8aa9b82a42a5e34f422aa5.zip
Merge branch 'sunweaver-pr/tolerate-nonset-XDG-CURRENT-DESKTOP'
Attributes GH PR #19: https://github.com/AyatanaIndicators/ayatana-settings/pull/19
-rwxr-xr-xayatana-settings5
1 files changed, 4 insertions, 1 deletions
diff --git a/ayatana-settings b/ayatana-settings
index a8ea538..7daae0a 100755
--- a/ayatana-settings
+++ b/ayatana-settings
@@ -48,7 +48,10 @@ class AyatanaSettings:
self.bSystemd = isSystemd()
self.bInit = False
- self.sDesktop = os.environ['XDG_CURRENT_DESKTOP']
+ try:
+ self.sDesktop = os.environ['XDG_CURRENT_DESKTOP']
+ except KeyError:
+ self.sDesktop = ""
# Session
if Gio.SettingsSchemaSource.get_default().lookup('org.ayatana.indicator.session', False):