@@ -2,7 +2,7 @@ import { Buffer as NBuffer } from 'buffer';
2
2
import * as bcrypto from '../crypto' ;
3
3
4
4
import { varuint } from '../bufferutils' ;
5
- import { TaprootLeaf } from '../types' ;
5
+ import { Taptree } from '../types' ;
6
6
7
7
const TAP_LEAF_TAG = 'TapLeaf' ;
8
8
const TAP_BRANCH_TAG = 'TapBranch' ;
@@ -45,7 +45,7 @@ export interface HashTree {
45
45
* - a pair of two taproot leafs [(output, version), (output, version)], or
46
46
* - one taproot leaf and a list of elements
47
47
*/
48
- export function toHashTree ( scriptTree : TaprootLeaf [ ] ) : HashTree {
48
+ export function toHashTree ( scriptTree : Taptree ) : HashTree {
49
49
if ( scriptTree . length === 1 ) {
50
50
const script = scriptTree [ 0 ] ;
51
51
if ( Array . isArray ( script ) ) {
@@ -71,9 +71,9 @@ export function toHashTree(scriptTree: TaprootLeaf[]): HashTree {
71
71
} ;
72
72
}
73
73
/**
74
- * Check if the tree is a binary tree with leafs of type TaprootLeaf
74
+ * Check if the tree is a binary tree with leafs of type Tapleaf
75
75
*/
76
- export function isTapTree ( scriptTree : TaprootLeaf [ ] ) : boolean {
76
+ export function isTapTree ( scriptTree : Taptree ) : boolean {
77
77
if ( scriptTree . length > 2 ) return false ;
78
78
if ( scriptTree . length === 1 ) {
79
79
const script = scriptTree [ 0 ] ;
0 commit comments