Use tracing for logging

This commit is contained in:
Dreaded_X 2025-03-15 05:53:17 +01:00
parent 28fe0e333d
commit 59f26a7e75
Signed by: Dreaded_X
GPG Key ID: FA5F485356B0D2D4

View File

@ -1,6 +1,7 @@
use anyhow::{anyhow, Context};
use lldap_auth::{opaque, registration};
use surf::Client;
use tracing::debug;
pub async fn change_password(client: &Client, user_id: &str, password: &str) -> anyhow::Result<()> {
let mut rng = rand::rngs::OsRng;
@ -42,7 +43,7 @@ pub async fn change_password(client: &Client, user_id: &str, password: &str) ->
.await
.map_err(|e| anyhow!(e))?;
println!("Changed '{user_id}' password successfully");
debug!("Changed '{user_id}' password successfully");
Ok(())
}