freqtradebot.leverage_prep moved wallet_balance to a variable

This commit is contained in:
Sam Germain 2022-01-31 13:21:27 -06:00
parent 8b9abd0051
commit 430051275a

View File

@ -618,12 +618,13 @@ class FreqtradeBot(LoggingMixin):
self.collateral_type == Collateral.ISOLATED and self.collateral_type == Collateral.ISOLATED and
self.trading_mode == TradingMode.FUTURES self.trading_mode == TradingMode.FUTURES
): ):
wallet_balance = (amount * open_rate)/leverage
isolated_liq = self.exchange.get_liquidation_price( isolated_liq = self.exchange.get_liquidation_price(
pair=pair, pair=pair,
open_rate=open_rate, open_rate=open_rate,
is_short=is_short, is_short=is_short,
position=amount, position=amount,
wallet_balance=(amount * open_rate)/leverage, # TODO: Update for cross wallet_balance=wallet_balance,
mm_ex_1=0.0, mm_ex_1=0.0,
upnl_ex_1=0.0, upnl_ex_1=0.0,
) )