Skip to content

Commit 107a1b4

Browse files
committed
fix: fix trade detail deser (bitfinex doc is incorrect )
1 parent 348af16 commit 107a1b4

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

src/account.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ pub struct TradeDetail {
1919
pub order_id: i64,
2020
pub order_id_oppo: i64,
2121
pub trade_price: String,
22-
pub trade_amount: f64,
22+
pub trade_amount: String,
2323
pub order_cid: i64,
24-
pub order_gid: i64,
24+
pub order_gid: Option<i64>,
2525
}
2626

2727
#[derive(Serialize, Deserialize)]
@@ -92,7 +92,6 @@ impl Account {
9292
pub fn get_wallets(&self) -> Result<Vec<Wallet>> {
9393
let payload: String = format!("{}", "{}");
9494
let data = self.client.post_signed("r/wallets".into(), payload)?;
95-
9695
let wallets: Vec<Wallet> = from_str(data.as_str())?;
9796

9897
Ok(wallets)

0 commit comments

Comments
 (0)