Implement first stop method
This commit is contained in:
@@ -24,21 +24,16 @@ class ProtectionResolver(IResolver):
|
||||
initial_search_path = Path(__file__).parent.parent.joinpath('plugins/protections').resolve()
|
||||
|
||||
@staticmethod
|
||||
def load_protection(protection_name: str, exchange, protectionmanager,
|
||||
config: Dict, protection_config: Dict) -> IProtection:
|
||||
def load_protection(protection_name: str, config: Dict, protection_config: Dict) -> IProtection:
|
||||
"""
|
||||
Load the protection with protection_name
|
||||
:param protection_name: Classname of the pairlist
|
||||
:param exchange: Initialized exchange class
|
||||
:param protectionmanager: Initialized protection manager
|
||||
:param config: configuration dictionary
|
||||
:param protection_config: Configuration dedicated to this pairlist
|
||||
:return: initialized Protection class
|
||||
"""
|
||||
return ProtectionResolver.load_object(protection_name, config,
|
||||
kwargs={'exchange': exchange,
|
||||
'pairlistmanager': protectionmanager,
|
||||
'config': config,
|
||||
'pairlistconfig': protection_config,
|
||||
kwargs={'config': config,
|
||||
'protection_config': protection_config,
|
||||
},
|
||||
)
|
||||
|
Reference in New Issue
Block a user