File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
governance/xc_admin/packages/xc_admin_cli/src Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -386,7 +386,7 @@ multisigCommand(
386
386
"Deactivate the delegated stake from the account"
387
387
)
388
388
. requiredOption (
389
- "-s, --stake-accounts <accounts... >" ,
389
+ "-s, --stake-accounts <comma_separated_stake_account >" ,
390
390
"stake accounts to be deactivated"
391
391
)
392
392
. action ( async ( options : any ) => {
@@ -395,10 +395,15 @@ multisigCommand(
395
395
const authorizedPubkey : PublicKey = await vault . getVaultAuthorityPDA (
396
396
cluster
397
397
) ;
398
- const instructions = options . stakeAccounts . reduce (
399
- ( instructions : TransactionInstruction [ ] , stakeAccount : string ) => {
398
+
399
+ const stakeAccounts = options . stakeAccounts
400
+ ? options . stakeAccounts . split ( "," ) . map ( ( m : string ) => new PublicKey ( m ) )
401
+ : [ ] ;
402
+
403
+ const instructions = stakeAccounts . reduce (
404
+ ( instructions : TransactionInstruction [ ] , stakeAccount : PublicKey ) => {
400
405
const transaction = StakeProgram . deactivate ( {
401
- stakePubkey : new PublicKey ( stakeAccount ) ,
406
+ stakePubkey : stakeAccount ,
402
407
authorizedPubkey,
403
408
} ) ;
404
409
You can’t perform that action at this time.
0 commit comments