mirror of
https://github.com/zedeus/nitter.git
synced 2024-11-14 12:41:12 +00:00
Set default theme if not set
This commit is contained in:
parent
51a5c473ae
commit
08845922f4
1 changed files with 2 additions and 0 deletions
|
@ -49,6 +49,8 @@ proc getPrefs*(id: string; cfg: Config): Prefs =
|
|||
withDb:
|
||||
try:
|
||||
result.getOne("id = ?", id)
|
||||
if result.theme.len == 0:
|
||||
result.theme = cfg.defaultTheme
|
||||
except KeyError:
|
||||
result = getDefaultPrefs(cfg)
|
||||
|
||||
|
|
Loading…
Reference in a new issue