Skip to content

Commit

Permalink
Upgrade some package
Browse files Browse the repository at this point in the history
  • Loading branch information
hongquan committed Nov 23, 2023
1 parent 0cf035f commit 0f1d59b
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 38 deletions.
25 changes: 7 additions & 18 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ axum-login = "0.9.0"
chrono = { version = "0.4.26", features = ["serde", "alloc", "clock"], default-features = false }
chrono-tz = { version = "0.8.3", features = ["serde"] }
clap = { version = "4.4.7", features = ["derive"] }
comrak = "0.18.0"
comrak = "0.19.0"
config = { version = "0.13.3", default-features = false, features = ["indexmap", "toml"] }
djangohashers = { version = "1.6.7", default-features = false, features = ["with_argon2"] }
edgedb-derive = "0.5.1"
Expand All @@ -29,7 +29,7 @@ edgedb-tokio = { version = "0.5.0", features = ["serde_json", "miette-errors"] }
field_names = "0.2.0"
fluent-bundle = "0.15.2"
fluent-templates = "0.8.0"
fred = { version = "7.0.0", features = ["serde-json", "partial-tracing"] }
fred = { version = "7.0.0", features = ["tracing"] }
http = "0.2.9"
hyperlocal = { version = "0.8.0", default-features = false, features = ["server"] }
indexmap = { version = "2.0.0", features = ["serde"] }
Expand All @@ -54,7 +54,7 @@ syntect = { version = "5.0.0", default-features = false, features = ["fancy-rege
thiserror = "1.0.50"
tokio = { version = "1.29.1", features = ["full"] }
tower = { version = "0.4.13", features = ["tracing", "tokio"] }
tower-http = { version = "0.4.1", features = ["trace"] }
tower-http = { version = "0.4.4", features = ["trace"] }
tower-sessions = { version = "0.6.0", features = ["redis-store"] }
tracing = { git = "https://github.com/hongquan/tracing.git", branch = "feat/tracing-journald" }
tracing-journald = { git = "https://github.com/hongquan/tracing.git", branch = "feat/tracing-journald" }
Expand Down
17 changes: 0 additions & 17 deletions src/api/auth.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,23 +35,6 @@ pub async fn login(
info!("Failed to authenticate");
ApiError::LoginError("Wrong email or password".into())
})?;
// let user = stores::user::get_user_by_email(&login_data.email, &db)
// .await
// .map_err(ApiError::EdgeDBQueryError)?
// .ok_or_else(|| {
// tracing::info!("User not found");
// let resp: ApiErrorShape = "User not found".to_string().into();
// (StatusCode::UNAUTHORIZED, Json(resp))
// })?;
// let passwd_check = check_password(login_data.password.expose_secret(), &user.password)
// .map_err(|e| {
// tracing::error!("Error checking password: {:?}", e);
// ApiError::LoginError("Wrong password".into())
// })?;
// tracing::info!("Password check: {:?}", passwd_check);
// passwd_check
// .then_some(())
// .ok_or(ApiError::LoginError("Wrong password".into()))?;
info!("Logging in user: {:?}", user);
auth_session.login(&user).await.map_err(|e| {
tracing::error!("Error logging in user: {}", e);
Expand Down

0 comments on commit 0f1d59b

Please sign in to comment.