diff options
author | Ryan Huber <rhuber@gmail.com> | 2017-01-26 13:34:55 -0800 |
---|---|---|
committer | Ryan Huber <rhuber@gmail.com> | 2017-01-26 13:34:55 -0800 |
commit | 01beb42fec5c6dbfc0d8c53ce1de88b48b48f6db (patch) | |
tree | 71e2e8523e763da0aa41eb4b07e639006ebd0851 /wee_slack.py | |
parent | 85ca2dd820d64d1ce717ba44338f6dc26fe9e886 (diff) | |
download | wee-slack-01beb42fec5c6dbfc0d8c53ce1de88b48b48f6db.tar.gz |
Make this fail back to the default for testability0.99.11
Diffstat (limited to 'wee_slack.py')
-rw-r--r-- | wee_slack.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/wee_slack.py b/wee_slack.py index 73b0d79..ed96f03 100644 --- a/wee_slack.py +++ b/wee_slack.py @@ -2497,7 +2497,10 @@ class PluginConfig(object): def fetch_setting(self, key): if hasattr(self, 'get_' + key): - return getattr(self, 'get_' + key)(key) + try: + return getattr(self, 'get_' + key)(key) + except: + return self.settings[key] else: # Most settings are on/off, so make get_boolean the default return self.get_boolean(key) |