Use namedtuple for sell_return

This commit is contained in:
Matthias
2018-07-12 22:21:52 +02:00
parent ad98c62329
commit a452864b41
5 changed files with 29 additions and 19 deletions

View File

@@ -508,8 +508,8 @@ class FreqtradeBot(object):
trade.pair, self.strategy.ticker_interval)
should_sell = self.strategy.should_sell(trade, current_rate, datetime.utcnow(), buy, sell)
if should_sell[0]:
self.execute_sell(trade, current_rate, should_sell[1])
if should_sell.sell_flag:
self.execute_sell(trade, current_rate, should_sell.sell_type)
return True
logger.info('Found no sell signals for whitelisted currencies. Trying again..')
return False