Move get_trade_stake_amount to wallets

this way it can be easier used by other functions
This commit is contained in:
Matthias
2021-02-03 20:00:33 +01:00
parent 6c87c49871
commit b8cb39462c
5 changed files with 104 additions and 93 deletions

View File

@@ -590,7 +590,8 @@ class RPC:
raise RPCException(f'position for {pair} already open - id: {trade.id}')
# gen stake amount
stakeamount = self._freqtrade.get_trade_stake_amount(pair)
stakeamount = self._freqtrade.wallets.get_trade_stake_amount(
pair, self._freqtrade.get_free_open_trades())
# execute buy
if self._freqtrade.execute_buy(pair, stakeamount, price):