From 69bf30bd61f6afa07447035922aafbb1ddb711fe Mon Sep 17 00:00:00 2001 From: JoeGruff Date: Fri, 10 May 2024 12:13:14 +0900 Subject: [PATCH] walletloader: Set balance confirms to one. If set to zero AccountBalances will bundle unconfirmed transactions into Spendable. --- cgo/walletloader.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cgo/walletloader.go b/cgo/walletloader.go index 5553cec..ae6e38d 100644 --- a/cgo/walletloader.go +++ b/cgo/walletloader.go @@ -183,7 +183,8 @@ func walletBalance(cName *C.char) *C.char { return errCResponse("wallet with name %q not loaded", goString(cName)) } - bals, err := w.AccountBalances(ctx, 0) + const confs = 1 + bals, err := w.AccountBalances(ctx, confs) if err != nil { return errCResponse("w.AccountBalances error: %v", err) }