Remove TransactionWrapper from SDK & Balancer.

This type is not needed anymore.
This commit is contained in:
kayibal
2024-03-13 21:07:46 +00:00
parent d9fe9b1e1c
commit 18e9dfcec4
3 changed files with 0 additions and 37 deletions

View File

@@ -2,5 +2,3 @@ pub mod balances;
pub mod contract;
mod mock_store;
pub mod pb;
// TODO: consider removing this module, after integrating with balancer
pub mod utils;

View File

@@ -1,24 +0,0 @@
use crate::pb::tycho::evm::v1::Transaction;
/// This struct purely exists to spoof the `PartialEq` trait for `Transaction` so we can use it in
/// a later groupby operation.
#[derive(Debug)]
pub struct TransactionWrapper(Transaction);
impl TransactionWrapper {
pub fn new(tx: Transaction) -> Self {
Self(tx)
}
}
impl PartialEq for TransactionWrapper {
fn eq(&self, other: &Self) -> bool {
self.0.hash == other.0.hash
}
}
impl From<TransactionWrapper> for Transaction {
fn from(value: TransactionWrapper) -> Self {
value.0
}
}