Merge pull request #8211 from TheJoeSchr/refactor-1

refactor(if-gate): use temp variable instead of if-gate
This commit is contained in:
Matthias 2023-02-23 18:14:21 +01:00 committed by GitHub
commit 2fed924a0d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -424,10 +424,8 @@ class DataProvider:
""" """
if self._exchange is None: if self._exchange is None:
raise OperationalException(NO_EXCHANGE_EXCEPTION) raise OperationalException(NO_EXCHANGE_EXCEPTION)
if helping_pairs: final_pairs = (pairlist + helping_pairs) if helping_pairs else pairlist
self._exchange.refresh_latest_ohlcv(pairlist + helping_pairs) self._exchange.refresh_latest_ohlcv(final_pairs)
else:
self._exchange.refresh_latest_ohlcv(pairlist)
@property @property
def available_pairs(self) -> ListPairsWithTimeframes: def available_pairs(self) -> ListPairsWithTimeframes: