mirror of
https://github.com/logos-blockchain/lssa.git
synced 2026-02-17 03:43:10 +00:00
fmt, clippy
This commit is contained in:
parent
177235a2c7
commit
32c36af126
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -254,7 +254,7 @@ impl indexer_service_rpc::RpcServer for MockIndexerService {
|
||||
.collect();
|
||||
|
||||
// Sort by block ID descending (most recent first)
|
||||
account_txs.sort_by(|a, b| b.1.cmp(&a.1));
|
||||
account_txs.sort_by_key(|b| std::cmp::Reverse(b.1));
|
||||
|
||||
let start = offset as usize;
|
||||
if start >= account_txs.len() {
|
||||
|
||||
@ -118,7 +118,7 @@ pub fn add_liquidity(
|
||||
assert!(delta_lp != 0, "Payable LP must be nonzero");
|
||||
|
||||
assert!(
|
||||
delta_lp >= min_amount_liquidity.into(),
|
||||
delta_lp >= min_amount_liquidity.get(),
|
||||
"Payable LP is less than provided minimum LP amount"
|
||||
);
|
||||
|
||||
|
||||
@ -298,6 +298,8 @@ impl WalletCore {
|
||||
instruction_data: InstructionData,
|
||||
program: &ProgramWithDependencies,
|
||||
) -> Result<(SendTxResponse, Vec<SharedSecretKey>), ExecutionFailureKind> {
|
||||
// TODO: handle large Err-variant properly
|
||||
#[allow(clippy::result_large_err)]
|
||||
self.send_privacy_preserving_tx_with_pre_check(accounts, instruction_data, program, |_| {
|
||||
Ok(())
|
||||
})
|
||||
|
||||
@ -20,6 +20,9 @@ fn auth_transfer_preparation(
|
||||
) {
|
||||
let instruction_data = Program::serialize_instruction(balance_to_move).unwrap();
|
||||
let program = Program::authenticated_transfer_program();
|
||||
|
||||
// TODO: handle large Err-variant properly
|
||||
#[allow(clippy::result_large_err)]
|
||||
let tx_pre_check = move |accounts: &[&Account]| {
|
||||
let from = accounts[0];
|
||||
if from.balance >= balance_to_move {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user