Skip to content

Commit f92269d

Browse files
committed
Allow user to enable debug logging
1 parent f523f7b commit f92269d

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

SettingsTemplate.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,9 @@ body:
1515
label: "Show all games with empty search"
1616
defaultValue: "true"
1717
description: "Shows all games when search Query is empty and the Action Keyword is used"
18+
- type: checkbox
19+
attributes:
20+
name: Debug
21+
label: "Debug"
22+
defaultValue: "false"
23+
description: "Enable Debug logging"

plugin/main.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ def query(self, query):
1414
self._steam = Steam(self.settings.get('steam_path', None))
1515
if not self.settings.get('steam_path'):
1616
self.settings['steam_path'] = str(self._steam.path)
17+
debug = self.settings.get('debug', False)
18+
if debug:
19+
self.logger_level = 'DEBUG'
1720
games = self._steam.all_games()
1821
users = self._steam.loginusers()
1922
most_recent_user = users.most_recent() or users[0]

0 commit comments

Comments
 (0)