From 09db4bcaddb2ef85a7bf28105cc1392fda9d087c Mon Sep 17 00:00:00 2001 From: Matthias Date: Sun, 23 Jan 2022 17:00:00 +0100 Subject: [PATCH] Don't use strings, use methods directly --- freqtrade/strategy/interface.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/freqtrade/strategy/interface.py b/freqtrade/strategy/interface.py index ac1285025..16d8ee818 100644 --- a/freqtrade/strategy/interface.py +++ b/freqtrade/strategy/interface.py @@ -872,9 +872,9 @@ class IStrategy(ABC, HyperStrategyMixin): and ordertime < timeout_threshold) if timedout: return True - time_method = 'check_sell_timeout' if order['side'] == 'sell' else 'check_buy_timeout' + time_method = self.check_sell_timeout if order['side'] == 'sell' else self.check_buy_timeout - return strategy_safe_wrapper(getattr(self, time_method), + return strategy_safe_wrapper(time_method, default_retval=False)( pair=trade.pair, trade=trade, order=order, current_time=current_time)