Skip to content

Commit

Permalink
multi-account: update listsinceblock
Browse files Browse the repository at this point in the history
  • Loading branch information
roylee17 committed Sep 28, 2022
1 parent 1edb90e commit 51e700e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion rpc/legacyrpc/methods.go
Original file line number Diff line number Diff line change
Expand Up @@ -1466,7 +1466,7 @@ func listSinceBlock(icmd interface{}, w *wallet.Wallet, chainClient *chain.RPCCl
start = int32(block.Height) + 1
}

txInfoList, err := w.ListSinceBlock(start, -1, syncBlock.Height)
txInfoList, err := w.ListSinceBlock("*", start, -1, syncBlock.Height)
if err != nil {
return nil, err
}
Expand Down
6 changes: 3 additions & 3 deletions wallet/wallet.go
Original file line number Diff line number Diff line change
Expand Up @@ -2049,7 +2049,7 @@ outputs:
// ListSinceBlock returns a slice of objects with details about transactions
// since the given block. If the block is -1 then all transactions are included.
// This is intended to be used for listsinceblock RPC replies.
func (w *Wallet) ListSinceBlock(start, end, syncHeight int32) ([]btcjson.ListTransactionsResult, error) {
func (w *Wallet) ListSinceBlock(accountName string, start, end, syncHeight int32) ([]btcjson.ListTransactionsResult, error) {
txList := []btcjson.ListTransactionsResult{}
err := walletdb.View(w.db, func(tx walletdb.ReadTx) error {
txmgrNs := tx.ReadBucket(wtxmgrNamespaceKey)
Expand All @@ -2059,8 +2059,8 @@ func (w *Wallet) ListSinceBlock(start, end, syncHeight int32) ([]btcjson.ListTra
detail := detail

jsonResults := listTransactions(
tx, &detail, w.Manager, syncHeight,
w.chainParams,
accountName, tx, &detail, w.Manager,
syncHeight, w.chainParams,
)
txList = append(txList, jsonResults...)
}
Expand Down

0 comments on commit 51e700e

Please sign in to comment.