@@ -3,7 +3,7 @@ This module loads custom exchanges
|
||||
"""
|
||||
import logging
|
||||
|
||||
from freqtrade.exchange import Exchange
|
||||
from freqtrade.exchange import Exchange, MAP_EXCHANGE_CHILDCLASS
|
||||
import freqtrade.exchange as exchanges
|
||||
from freqtrade.resolvers import IResolver
|
||||
|
||||
@@ -22,6 +22,8 @@ class ExchangeResolver(IResolver):
|
||||
Load the custom class from config parameter
|
||||
:param config: configuration dictionary
|
||||
"""
|
||||
# Map exchange name to avoid duplicate classes for identical exchanges
|
||||
exchange_name = MAP_EXCHANGE_CHILDCLASS.get(exchange_name, exchange_name)
|
||||
exchange_name = exchange_name.title()
|
||||
try:
|
||||
self.exchange = self._load_exchange(exchange_name, kwargs={'config': config})
|
||||
|
Reference in New Issue
Block a user