Always normalise vaultId and trim token
This commit is contained in:
parent
04a24d0b38
commit
74a8060246
11 changed files with 44 additions and 10 deletions
|
|
@ -13,11 +13,13 @@ use super::{auth::auth, responses::PingResponse};
|
|||
use crate::{
|
||||
app_state::{AppState, database::models::VaultId},
|
||||
errors::SyncServerError,
|
||||
utils::normalize::normalize,
|
||||
};
|
||||
|
||||
// This is required for aide to infer the path parameter types and names
|
||||
#[derive(Deserialize, JsonSchema)]
|
||||
pub struct PingPathParams {
|
||||
#[serde(deserialize_with = "normalize")]
|
||||
vault_id: VaultId,
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue