Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
0xIchigo committed May 22, 2024
1 parent bf0ab25 commit 83d29f9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/optimized_transaction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use crate::Helius;

use base64::engine::general_purpose::STANDARD;
use base64::Engine;
use bincode::{ErrorKind, serialize};
use bincode::{serialize, ErrorKind};
use reqwest::StatusCode;
use solana_client::rpc_config::RpcSendTransactionConfig;
use solana_client::rpc_response::{Response, RpcSimulateTransactionResult};
Expand Down Expand Up @@ -120,7 +120,8 @@ impl Helius {
transaction.try_sign(&[config.from_keypair], recent_blockhash)?;

// Serialize the transaction
let serialized_transaction: Vec<u8> = serialize(&transaction).map_err(|e: Box<ErrorKind>| HeliusError::InvalidInput(e.to_string()))?;
let serialized_transaction: Vec<u8> =
serialize(&transaction).map_err(|e: Box<ErrorKind>| HeliusError::InvalidInput(e.to_string()))?;

// Convert the serialized transaction to a Base64 string
let transaction_base64: String = STANDARD.encode(&serialized_transaction);
Expand Down

0 comments on commit 83d29f9

Please sign in to comment.