Skip to content

Commit 46cd679

Browse files
OttoAllmendingerllm-git
andcommitted
fix(utxo-staking): update createProofOfPossession method signature
Add channel parameter to match the signature in the parent class. The channel parameter indicates the context in which the proof of possession is created. Issue: BTC-2402 Co-authored-by: llm-git <[email protected]>
1 parent 6c9df95 commit 46cd679

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

modules/utxo-staking/src/babylon/stakingManager.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,11 +68,16 @@ class BitGoStakingManager extends vendor.BabylonBtcStakingManager {
6868

6969
/**
7070
* Creates a proof of possession for the staker based on ECDSA signature.
71+
* @param channel - The channel for which the proof of possession is created.
7172
* @param bech32Address - The staker's bech32 address on the babylon network.
7273
* @param stakerBtcAddress
7374
* @returns The proof of possession.
7475
*/
75-
async createProofOfPossession(bech32Address: string, stakerBtcAddress: string): Promise<ProofOfPossessionBTC> {
76+
override async createProofOfPossession(
77+
channel: 'delegation:create' | 'delegation:register',
78+
bech32Address: string,
79+
stakerBtcAddress: string
80+
): Promise<ProofOfPossessionBTC> {
7681
// force the ECDSA signature type
7782
return this.createProofOfPossessionWithSigType(bech32Address, stakerBtcAddress, BTCSigType.ECDSA);
7883
}

0 commit comments

Comments
 (0)