Fix crash due to insufficient check

This commit is contained in:
Matthias 2022-09-25 09:47:57 +02:00
parent 30d51b6939
commit 1bb45a2650

View File

@ -34,7 +34,7 @@ class ProducerPairList(IPairList):
self._num_assets: int = self._pairlistconfig.get('number_assets', 0) self._num_assets: int = self._pairlistconfig.get('number_assets', 0)
self._producer_name = self._pairlistconfig.get('producer_name', 'default') self._producer_name = self._pairlistconfig.get('producer_name', 'default')
if config.get('external_message_consumer').get('enabled') is False: if config.get('external_message_consumer', {}).get('enabled') is False:
raise ValueError("ProducerPairList requires external_message_consumer to be enabled.") raise ValueError("ProducerPairList requires external_message_consumer to be enabled.")
@property @property