Skip to content

Commit 41d9246

Browse files
authored
Merge pull request #6587 from BitGo/win-4343-unsigned-sweep
feat(abstract-cosmos): fix the public key in usigned sweep
2 parents 7de40d4 + ca64c83 commit 41d9246

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

modules/abstract-cosmos/src/cosmosCoin.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,9 @@ export class CosmosCoin<CustomMessage = never> extends BaseCoin {
223223

224224
if (publicKey) {
225225
txnBuilder.publicKey(publicKey);
226+
} else {
227+
publicKey = MPC.deriveUnhardened(params.bitgoKey || '', ROOT_PATH).slice(0, 66);
228+
txnBuilder.publicKey(publicKey);
226229
}
227230

228231
const unsignedTransaction = (await txnBuilder.build()) as CosmosTransaction<CustomMessage>;

0 commit comments

Comments
 (0)