From 1f548df283c0c376b6064c62eab50ab9ff1c853f Mon Sep 17 00:00:00 2001 From: Valmo Trindade Date: Sun, 15 Sep 2024 19:12:28 -0300 Subject: [PATCH] added login info struct --- src/structs.rs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/structs.rs b/src/structs.rs index 29ed2b2..477c55b 100644 --- a/src/structs.rs +++ b/src/structs.rs @@ -1,5 +1,5 @@ use arma_rs::FromArma; -use serde::Serialize; +use serde::{Deserialize, Serialize}; #[derive(Serialize)] pub struct Marker { @@ -55,13 +55,19 @@ impl FromArma for Marker { } } -#[derive(Serialize)] +#[derive(Debug, Serialize, Deserialize)] pub struct LoginPayload { pub address: String, pub username: String, pub password: String, } +#[derive(Debug, Serialize, Deserialize)] +pub struct LoginInfo { + pub username: String, + pub password: String +} + impl FromArma for LoginPayload { fn from_arma(data: String) -> Result { let (address, username, password) = <(String, String, String)>::from_arma(data)?;