Skip to content

Commit

Permalink
remove unused imports
Browse files Browse the repository at this point in the history
  • Loading branch information
rwwwx committed Aug 20, 2024
1 parent f4aafdb commit 6245ada
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 18 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::{clock_unix_timestamp, cpi_instructions, find_mining_address};
use crate::{clock_unix_timestamp, cpi_instructions};
use anchor_lang::prelude::*;
use mplx_staking_states::{
error::MplStakingError,
Expand Down
18 changes: 1 addition & 17 deletions programs/voter-stake-registry/src/instructions/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ pub use create_voter::*;
pub use deposit::*;
pub use extend_stake::*;
pub use log_voter_info::*;
use solana_program::{clock::Clock, pubkey::Pubkey, sysvar::Sysvar};
use solana_program::{clock::Clock, sysvar::Sysvar};
pub use stake::*;
pub use unlock_tokens::*;
pub use update_voter_weight_record::*;
Expand All @@ -34,19 +34,3 @@ mod withdraw;
pub fn clock_unix_timestamp() -> u64 {
Clock::get().unwrap().unix_timestamp as u64
}

/// Generates mining address
pub fn find_mining_address(
program_id: &Pubkey,
mining_owner: &Pubkey,
reward_pool: &Pubkey,
) -> (Pubkey, u8) {
Pubkey::find_program_address(
&[
"mining".as_bytes(),
&mining_owner.to_bytes(),
&reward_pool.to_bytes(),
],
program_id,
)
}

0 comments on commit 6245ada

Please sign in to comment.