Skip to content

Commit d77e76b

Browse files
Merge pull request #6804 from BitGo/WP-000000/fix/opeth-staking
fix(sdk-core): rely on wallet field to validate txrequest on staking
2 parents 6ed0aaf + 9ee96f1 commit d77e76b

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

modules/bitgo/test/v2/unit/staking/stakingWalletTSS.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ describe('TSS Staking Wallet', function () {
3939
coin: 'near',
4040
enterprise: enterprise.id,
4141
keys: ['5b3424f91bf349930e340175'],
42+
multisigType: 'tss',
4243
};
4344
const nearWallet = new Wallet(bitgo, nearBaseCoin, tssWalletData);
4445
nearStakingWallet = nearWallet.toStakingWallet();

modules/sdk-core/src/bitgo/staking/stakingWallet.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ export class StakingWallet implements IStakingWallet {
136136
* @param transaction - staking transaction to build
137137
*/
138138
async build(transaction: StakingTransaction): Promise<StakingPrebuildTransactionResult> {
139-
if ((this.wallet.baseCoin.supportsTss() && this.wallet.baseCoin.getFamily() !== 'eth') || this.isEthTss) {
139+
if ((this.wallet.multisigType() === 'tss' && this.wallet.baseCoin.getFamily() !== 'eth') || this.isEthTss) {
140140
if (!transaction.txRequestId) {
141141
throw new Error('txRequestId is required to sign and send');
142142
}

0 commit comments

Comments
 (0)