Merge pull request #4570 from wpaulino/listtransactions-skip-unsupported-addr
btcwallet: skip unsupported addresses in ListTransasctionDetails
This commit is contained in:
1 file changed
+6
-2
@@ -558,7 +558,9 @@ func minedTransactionsToDetails(
|
|||||||
txOut.PkScript, chainParams,
|
txOut.PkScript, chainParams,
|
||||||
)
|
)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
// Skip any unsupported addresses to prevent
|
||||||
|
// other transactions from not being returned.
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
destAddresses = append(destAddresses, outAddresses...)
|
destAddresses = append(destAddresses, outAddresses...)
|
||||||
@@ -607,7 +609,9 @@ func unminedTransactionsToDetail(
|
|||||||
_, outAddresses, _, err :=
|
_, outAddresses, _, err :=
|
||||||
txscript.ExtractPkScriptAddrs(txOut.PkScript, chainParams)
|
txscript.ExtractPkScriptAddrs(txOut.PkScript, chainParams)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
// Skip any unsupported addresses to prevent other
|
||||||
|
// transactions from not being returned.
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
destAddresses = append(destAddresses, outAddresses...)
|
destAddresses = append(destAddresses, outAddresses...)
|
||||||
|
|||||||
Reference in new issue
Block a user