From f0648e24a5dd111e8b287f5f115de4cf1572d9cb Mon Sep 17 00:00:00 2001 From: Oliver Gugger Date: Thu, 11 Apr 2024 14:23:59 +0200 Subject: [PATCH] lnwallet: export GenTaprootHtlcScript --- lnwallet/commitment.go | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/lnwallet/commitment.go b/lnwallet/commitment.go index 6b6e8f5c2..dadf23431 100644 --- a/lnwallet/commitment.go +++ b/lnwallet/commitment.go @@ -1075,9 +1075,9 @@ func genSegwitV0HtlcScript(chanType channeldb.ChannelType, }, nil } -// genTaprootHtlcScript generates the HTLC scripts for a taproot+musig2 +// GenTaprootHtlcScript generates the HTLC scripts for a taproot+musig2 // channel. -func genTaprootHtlcScript(isIncoming bool, whoseCommit lntypes.ChannelParty, +func GenTaprootHtlcScript(isIncoming bool, whoseCommit lntypes.ChannelParty, timeout uint32, rHash [32]byte, keyRing *CommitmentKeyRing, ) (*input.HtlcScriptTree, error) { @@ -1138,8 +1138,7 @@ func genTaprootHtlcScript(isIncoming bool, whoseCommit lntypes.ChannelParty, // along side the multiplexer. func genHtlcScript(chanType channeldb.ChannelType, isIncoming bool, whoseCommit lntypes.ChannelParty, timeout uint32, rHash [32]byte, - keyRing *CommitmentKeyRing, -) (input.ScriptDescriptor, error) { + keyRing *CommitmentKeyRing) (input.ScriptDescriptor, error) { if !chanType.IsTaproot() { return genSegwitV0HtlcScript( @@ -1148,7 +1147,7 @@ func genHtlcScript(chanType channeldb.ChannelType, isIncoming bool, ) } - return genTaprootHtlcScript( + return GenTaprootHtlcScript( isIncoming, whoseCommit, timeout, rHash, keyRing, ) }