From b7ab02bcd932efcd52982eb6ecd04d7c0c2f986d Mon Sep 17 00:00:00 2001 From: ghassmo Date: Tue, 26 Apr 2022 00:35:32 +0300 Subject: [PATCH] wallet: remove WalletApi trait --- src/wallet/mod.rs | 1 - src/wallet/wallet_api.rs | 16 ---------------- 2 files changed, 17 deletions(-) delete mode 100644 src/wallet/wallet_api.rs diff --git a/src/wallet/mod.rs b/src/wallet/mod.rs index 8a1a521bc..08b54f990 100644 --- a/src/wallet/mod.rs +++ b/src/wallet/mod.rs @@ -1,3 +1,2 @@ pub mod cashierdb; -pub mod wallet_api; pub mod walletdb; diff --git a/src/wallet/wallet_api.rs b/src/wallet/wallet_api.rs deleted file mode 100644 index abc60646d..000000000 --- a/src/wallet/wallet_api.rs +++ /dev/null @@ -1,16 +0,0 @@ -use crate::{ - util::serial::{deserialize, serialize, Decodable, Encodable}, - Result, -}; - -pub trait WalletApi { - fn get_value_serialized(&self, data: &T) -> Result> { - let v = serialize(data); - Ok(v) - } - - fn get_value_deserialized(&self, key: Vec) -> Result { - let v: D = deserialize(&key)?; - Ok(v) - } -}