auto_repay icon indicating copy to clipboard operation
auto_repay copied to clipboard

auto borrow trigger

Open jellicoe opened this issue 3 years ago • 1 comments

in index.js

lines 563 to566

        }else if(nowPercent < **belowTrigger**){
            let ust_amount = parseInt((target_percent - percentNow) / percentNow * loanAmount)
            await repayHandler.borrow_ust(ust_amount)
        }

should this be target_percent, as belowTrigger is always -1 and is not the target value

        }else if(nowPercent < **target_percent**){
            let ust_amount = parseInt((target_percent - percentNow) / percentNow * loanAmount)
            await repayHandler.borrow_ust(ust_amount)
        }

jellicoe avatar May 06 '21 01:05 jellicoe