cmd: print quoted amount from InQuoteRequst

This commit is contained in:
Slyghtning 2025-10-07 10:58:04 +02:00
parent 68baebf478
commit 39b3752480
No known key found for this signature in database
GPG key ID: F82D456EA023C9BF

View file

@ -233,7 +233,13 @@ func printQuoteInResp(req *looprpc.QuoteRequest,
totalFee := resp.HtlcPublishFeeSat + resp.SwapFeeSat
if req.DepositOutpoints != nil {
fmt.Printf(satAmtFmt, "Previously deposited on-chain:", req.Amt)
if req.Amt == 0 {
fmt.Printf(satAmtFmt, "Previously deposited "+
"on-chain:", resp.QuotedAmt)
} else {
fmt.Printf(satAmtFmt, "Previously deposited "+
"on-chain:", req.Amt)
}
} else {
fmt.Printf(satAmtFmt, "Send on-chain:", req.Amt)
}