Skip to content

Commit

Permalink
Improve typing for API responses
Browse files Browse the repository at this point in the history
  • Loading branch information
dineshpinto committed Mar 22, 2024
1 parent a6c17d3 commit 137aace
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 20 deletions.
3 changes: 2 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
use std::time::{SystemTime, UNIX_EPOCH};

use crate::types::{
Dex, GeckoTerminalResponse, Network, Pool, Token, TokenInfo, TokenPrice, Trade, OHLCV,
dex::Dex, network::Network, ohlcv::OHLCV, pool::Pool, response::GeckoTerminalResponse,
simple::TokenPrice, token::Token, token_info::TokenInfo, trade::Trade,
};
use crate::validation::{
check_addresses, check_aggregate, check_currency, check_ohlcv_limit, check_page,
Expand Down
28 changes: 9 additions & 19 deletions src/types/mod.rs
Original file line number Diff line number Diff line change
@@ -1,19 +1,9 @@
pub use dex::Dex;
pub use network::Network;
pub use ohlcv::OHLCV;
pub use pool::Pool;
pub use response::GeckoTerminalResponse;
pub use simple::TokenPrice;
pub use token::Token;
pub use token_info::TokenInfo;
pub use trade::Trade;

mod dex;
mod network;
mod ohlcv;
mod pool;
mod response;
mod simple;
mod token;
mod token_info;
mod trade;
pub mod dex;
pub mod network;
pub mod ohlcv;
pub mod pool;
pub mod response;
pub mod simple;
pub mod token;
pub mod token_info;
pub mod trade;

0 comments on commit 137aace

Please sign in to comment.