mirror of
https://codeberg.org/demostf/frontend.git
synced 2026-06-03 18:24:12 +02:00
remove dummy session
This commit is contained in:
parent
a8f0d8e299
commit
bffa6e81d9
1 changed files with 2 additions and 13 deletions
|
|
@ -1,4 +1,3 @@
|
|||
use crate::data::steam_id::SteamId;
|
||||
use crate::data::user::User;
|
||||
use crate::{App, Result};
|
||||
use async_session::SessionStore as _;
|
||||
|
|
@ -43,12 +42,7 @@ where
|
|||
|
||||
// return the new created session cookie for client
|
||||
if session_cookie.is_none() {
|
||||
return Ok(Self::Authenticated(User {
|
||||
token: "token".into(),
|
||||
steam_id: SteamId::Id(76561198024494988),
|
||||
name: "Icewind".into(),
|
||||
}));
|
||||
// return Ok(Self::UnAuthenticated);
|
||||
return Ok(Self::UnAuthenticated);
|
||||
}
|
||||
|
||||
debug!(
|
||||
|
|
@ -60,12 +54,7 @@ where
|
|||
let Ok(Some(session)) = store
|
||||
.load_session(session_cookie.unwrap().to_owned())
|
||||
.await else {
|
||||
return Ok(Self::Authenticated(User {
|
||||
token: "token".into(),
|
||||
steam_id: SteamId::Id(76561198024494988),
|
||||
name: "Icewind".into(),
|
||||
}));
|
||||
// return Ok(Self::UnAuthenticated);
|
||||
return Ok(Self::UnAuthenticated);
|
||||
};
|
||||
let Some(user) = session.get::<User>("user") else {
|
||||
return Ok(Self::UnAuthenticated);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue