Switched to request
All checks were successful
Rust Build / Check (pull_request) Successful in 44s
Rust Build / Test Suite (pull_request) Successful in 53s
Rust Build / Rustfmt (pull_request) Successful in 32s
Rust Build / Clippy (pull_request) Successful in 49s
Rust Build / build (pull_request) Successful in 1m18s
All checks were successful
Rust Build / Check (pull_request) Successful in 44s
Rust Build / Test Suite (pull_request) Successful in 53s
Rust Build / Rustfmt (pull_request) Successful in 32s
Rust Build / Clippy (pull_request) Successful in 49s
Rust Build / build (pull_request) Successful in 1m18s
This commit is contained in:
@@ -37,7 +37,7 @@ pub mod response {
|
|||||||
|
|
||||||
pub async fn register_user(
|
pub async fn register_user(
|
||||||
axum::Extension(pool): axum::Extension<sqlx::PgPool>,
|
axum::Extension(pool): axum::Extension<sqlx::PgPool>,
|
||||||
Json(payload): Json<models::common::CreateUser>,
|
Json(payload): Json<request::Request>,
|
||||||
) -> (StatusCode, Json<response::Response>) {
|
) -> (StatusCode, Json<response::Response>) {
|
||||||
let mut user = models::common::User {
|
let mut user = models::common::User {
|
||||||
id: uuid::Uuid::nil(),
|
id: uuid::Uuid::nil(),
|
||||||
|
@@ -198,6 +198,10 @@ mod tests {
|
|||||||
let payload = json!({
|
let payload = json!({
|
||||||
"username": &usr.username,
|
"username": &usr.username,
|
||||||
"password": &usr.password,
|
"password": &usr.password,
|
||||||
|
"email": "dev@null.com",
|
||||||
|
"phone": "1234567890",
|
||||||
|
"firstname": "Bob",
|
||||||
|
"lastname": "Smith",
|
||||||
});
|
});
|
||||||
|
|
||||||
let response = app
|
let response = app
|
||||||
|
Reference in New Issue
Block a user