1
0

config: force 'history_rates' config var to bool

fixes https://github.com/spesmilo/electrum/issues/8367

probably regression from 503776c0de
(note that before that commit, we were casting to bool)
This commit is contained in:
SomberNight
2023-05-03 12:18:34 +00:00
parent 1a889d19b5
commit 3bdda3a861
5 changed files with 8 additions and 8 deletions

View File

@@ -592,8 +592,8 @@ class FxThread(ThreadJob, EventListener):
def can_have_history(self):
return self.is_enabled() and self.ccy in self.exchange.history_ccys()
def has_history(self):
return self.can_have_history() and self.config.get('history_rates', False)
def has_history(self) -> bool:
return self.can_have_history() and bool(self.config.get('history_rates', False))
def get_currency(self) -> str:
'''Use when dynamic fetching is needed'''