Changes
This commit is contained in:
parent
3a3f899ea2
commit
128b3191e7
68 changed files with 28060 additions and 1152 deletions
|
|
@ -79,13 +79,18 @@ async fn validate_token(
|
|||
.header("Authorization", format!("Bearer {token}"))
|
||||
.send()
|
||||
.await
|
||||
.map_err(|err| warn!("Token validation request failed: {err}"))
|
||||
.ok()?;
|
||||
|
||||
if !res.status().is_success() {
|
||||
return None;
|
||||
}
|
||||
|
||||
let body: AuthRefreshResponse = res.json().await.ok()?;
|
||||
let body: AuthRefreshResponse = res
|
||||
.json()
|
||||
.await
|
||||
.map_err(|err| warn!("Failed to parse auth refresh response: {err}"))
|
||||
.ok()?;
|
||||
Some(body.record)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue