findScriptPath
bitcoinjs-lib / payments / findScriptPath
Function: findScriptPath()
findScriptPath(
node
,hash
):undefined
|Uint8Array
[]
Defined in: ts_src/payments/bip341.ts:94
Given a HashTree, finds the path from a particular hash to the root.
Parameters
node
the root of the tree
hash
Uint8Array
the hash to search for
Returns
undefined
| Uint8Array
[]
- array of sibling hashes, from leaf (inclusive) to root (exclusive) needed to prove inclusion of the specified hash. undefined if no path is found