Final abs. profit should not be doubled in rpc messages
This commit is contained in:
parent
9df10c6b5b
commit
95327750dc
@ -1566,7 +1566,7 @@ class FreqtradeBot(LoggingMixin):
|
|||||||
profit_ratio = trade.calc_profit_ratio(profit_rate, amount, trade.open_rate)
|
profit_ratio = trade.calc_profit_ratio(profit_rate, amount, trade.open_rate)
|
||||||
else:
|
else:
|
||||||
profit_rate = trade.close_rate if trade.close_rate else trade.close_rate_requested
|
profit_rate = trade.close_rate if trade.close_rate else trade.close_rate_requested
|
||||||
profit = trade.calc_profit(rate=profit_rate) + trade.realized_profit
|
profit = trade.calc_profit(rate=profit_rate) + (0.0 if fill else trade.realized_profit)
|
||||||
profit_ratio = trade.calc_profit_ratio(profit_rate)
|
profit_ratio = trade.calc_profit_ratio(profit_rate)
|
||||||
amount = trade.amount
|
amount = trade.amount
|
||||||
gain = "profit" if profit_ratio > 0 else "loss"
|
gain = "profit" if profit_ratio > 0 else "loss"
|
||||||
|
Loading…
Reference in New Issue
Block a user