minor cleanup
This commit is contained in:
parent
091ddbf48a
commit
46232b4254
2 changed files with 3 additions and 6 deletions
|
@ -5,5 +5,3 @@ pub mod db;
|
||||||
pub mod handlers;
|
pub mod handlers;
|
||||||
pub(crate) mod templates;
|
pub(crate) mod templates;
|
||||||
pub mod users;
|
pub mod users;
|
||||||
|
|
||||||
//pub type Db: axum::
|
|
||||||
|
|
|
@ -2,13 +2,12 @@ use argon2::{
|
||||||
password_hash::{rand_core::OsRng, PasswordHash, PasswordHasher, PasswordVerifier, SaltString},
|
password_hash::{rand_core::OsRng, PasswordHash, PasswordHasher, PasswordVerifier, SaltString},
|
||||||
Argon2,
|
Argon2,
|
||||||
};
|
};
|
||||||
use askama::Template;
|
|
||||||
use axum::{
|
use axum::{
|
||||||
extract::{Form, Path, State},
|
extract::{Form, State},
|
||||||
http::StatusCode,
|
http::StatusCode,
|
||||||
response::IntoResponse,
|
response::IntoResponse,
|
||||||
};
|
};
|
||||||
use sqlx::{error::DatabaseError, Sqlite, SqlitePool};
|
use sqlx::SqlitePool;
|
||||||
use tracing::log::log;
|
use tracing::log::log;
|
||||||
use unicode_segmentation::UnicodeSegmentation;
|
use unicode_segmentation::UnicodeSegmentation;
|
||||||
use uuid::Uuid;
|
use uuid::Uuid;
|
||||||
|
@ -52,7 +51,7 @@ pub async fn get_create_user() -> CreateUser {
|
||||||
|
|
||||||
#[axum::debug_handler]
|
#[axum::debug_handler]
|
||||||
pub async fn post_create_user(
|
pub async fn post_create_user(
|
||||||
State(pool): State<sqlx::Pool<Sqlite>>,
|
State(pool): State<sqlx::SqlitePool>,
|
||||||
Form(signup): Form<CreateUser>,
|
Form(signup): Form<CreateUser>,
|
||||||
) -> Result<(), CreateUserError> {
|
) -> Result<(), CreateUserError> {
|
||||||
let username = &signup.username;
|
let username = &signup.username;
|
||||||
|
|
Loading…
Reference in a new issue