@@ -453,10 +453,10 @@ async fn build_instructions_for_ops(
453
453
& address,
454
454
& address,
455
455
& token. mint( ) ,
456
- & spl_token :: id ( ) ,
456
+ & token . program_id ( ) ,
457
457
) ,
458
458
system_instruction:: transfer( & address, & token. ata( & address) , amount) ,
459
- spl_token:: instruction:: sync_native( & spl_token :: id ( ) , & token. ata( & address) ) . unwrap( ) ,
459
+ spl_token:: instruction:: sync_native( & token . program_id ( ) , & token. ata( & address) ) . unwrap( ) ,
460
460
] ) ;
461
461
required_compute_units += 20_000 ;
462
462
}
@@ -468,7 +468,7 @@ async fn build_instructions_for_ops(
468
468
& address,
469
469
& address,
470
470
& token. mint ( ) ,
471
- & spl_token :: id ( ) ,
471
+ & token . program_id ( ) ,
472
472
) ,
473
473
) ;
474
474
required_compute_units += 25_000 ;
@@ -487,7 +487,7 @@ async fn build_instructions_for_ops(
487
487
488
488
let seed = & Keypair :: new ( ) . pubkey ( ) . to_string ( ) [ ..31 ] ;
489
489
let ephemeral_token_account =
490
- Pubkey :: create_with_seed ( & address, seed, & spl_token :: id ( ) ) . unwrap ( ) ;
490
+ Pubkey :: create_with_seed ( & address, seed, & token . program_id ( ) ) . unwrap ( ) ;
491
491
492
492
instructions. extend ( vec ! [
493
493
system_instruction:: create_account_with_seed(
@@ -497,17 +497,17 @@ async fn build_instructions_for_ops(
497
497
seed,
498
498
TOKEN_ACCOUNT_REQUIRED_LAMPORTS ,
499
499
spl_token:: state:: Account :: LEN as u64 ,
500
- & spl_token :: id ( ) ,
500
+ & token . program_id ( ) ,
501
501
) ,
502
502
spl_token:: instruction:: initialize_account(
503
- & spl_token :: id ( ) ,
503
+ & token . program_id ( ) ,
504
504
& ephemeral_token_account,
505
505
& token. mint( ) ,
506
506
& address,
507
507
)
508
508
. unwrap( ) ,
509
509
spl_token:: instruction:: transfer_checked(
510
- & spl_token :: id ( ) ,
510
+ & token . program_id ( ) ,
511
511
& token. ata( & address) ,
512
512
& token. mint( ) ,
513
513
& ephemeral_token_account,
@@ -518,7 +518,7 @@ async fn build_instructions_for_ops(
518
518
)
519
519
. unwrap( ) ,
520
520
spl_token:: instruction:: close_account(
521
- & spl_token :: id ( ) ,
521
+ & token . program_id ( ) ,
522
522
& ephemeral_token_account,
523
523
& address,
524
524
& address,
@@ -1894,7 +1894,7 @@ async fn mfi_deposit_or_withdraw(
1894
1894
// Bank Liquidity Vault
1895
1895
AccountMeta :: new( bank. liquidity_vault, false ) ,
1896
1896
// Token Program
1897
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
1897
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
1898
1898
] ,
1899
1899
) ;
1900
1900
@@ -1941,7 +1941,7 @@ async fn mfi_deposit_or_withdraw(
1941
1941
// Bank Liquidity Vault
1942
1942
AccountMeta :: new( bank. liquidity_vault, false ) ,
1943
1943
// Token Program
1944
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
1944
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
1945
1945
] ;
1946
1946
1947
1947
for balance in & user_account. lending_account . balances {
@@ -1961,7 +1961,7 @@ async fn mfi_deposit_or_withdraw(
1961
1961
& wallet_address,
1962
1962
& wallet_address,
1963
1963
& bank. mint,
1964
- & spl_token :: id ( ) ,
1964
+ & token . program_id ( ) ,
1965
1965
) ,
1966
1966
1967
1967
Instruction :: new_with_bytes(
@@ -2407,9 +2407,9 @@ fn kamino_deposit_or_withdraw(
2407
2407
// User Destination Collateral
2408
2408
AccountMeta :: new_readonly( KAMINO_LEND_PROGRAM , false ) ,
2409
2409
// Token Program
2410
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
2410
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
2411
2411
// Token Program
2412
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
2412
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
2413
2413
// Sysvar: Instructions
2414
2414
AccountMeta :: new_readonly( sysvar:: instructions:: ID , false ) ,
2415
2415
] ,
@@ -2458,9 +2458,9 @@ fn kamino_deposit_or_withdraw(
2458
2458
// User Destination Collateral
2459
2459
AccountMeta :: new_readonly( KAMINO_LEND_PROGRAM , false ) ,
2460
2460
// Token Program
2461
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
2461
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
2462
2462
// Token Program
2463
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
2463
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
2464
2464
// Sysvar: Instructions
2465
2465
AccountMeta :: new_readonly( sysvar:: instructions:: ID , false ) ,
2466
2466
] ,
@@ -2729,7 +2729,7 @@ fn solend_deposit_or_withdraw(
2729
2729
& wallet_address,
2730
2730
& wallet_address,
2731
2731
& reserve. collateral . mint_pubkey ,
2732
- & spl_token :: id ( ) ,
2732
+ & token . program_id ( ) ,
2733
2733
) ,
2734
2734
) ;
2735
2735
}
@@ -2773,7 +2773,7 @@ fn solend_deposit_or_withdraw(
2773
2773
// User Transfer Authority
2774
2774
AccountMeta :: new( wallet_address, true ) ,
2775
2775
// Token Program
2776
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
2776
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
2777
2777
] ,
2778
2778
) ) ;
2779
2779
( amount, 200_000 )
@@ -2885,7 +2885,7 @@ fn solend_deposit_or_withdraw(
2885
2885
// User Transfer Authority
2886
2886
AccountMeta :: new( wallet_address, true ) ,
2887
2887
// Token Program
2888
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
2888
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
2889
2889
] ;
2890
2890
2891
2891
for reserve_address in & obligation_market_reserves {
@@ -3088,7 +3088,7 @@ fn drift_deposit_or_withdraw(
3088
3088
false ,
3089
3089
) ,
3090
3090
// Token Program
3091
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
3091
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
3092
3092
// Spot Market Oracle
3093
3093
AccountMeta :: new_readonly( spot_market. oracle, false ) ,
3094
3094
// Spot Market
@@ -3138,7 +3138,7 @@ fn drift_deposit_or_withdraw(
3138
3138
false ,
3139
3139
) ,
3140
3140
// Token Program
3141
- AccountMeta :: new_readonly( spl_token :: id ( ) , false ) ,
3141
+ AccountMeta :: new_readonly( token . program_id ( ) , false ) ,
3142
3142
// Spot Market Oracle
3143
3143
AccountMeta :: new_readonly( spot_market. oracle, false ) ,
3144
3144
// Spot Market
0 commit comments