diff options
Diffstat (limited to 'src/main.rs')
| -rw-r--r-- | src/main.rs | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/main.rs b/src/main.rs index 0f39622..c5de543 100644 --- a/src/main.rs +++ b/src/main.rs @@ -100,10 +100,14 @@ async fn main() -> std::io::Result<()> { .route("/settings", web::get().to(user::settings)) .route("/reset-password", web::post().to(user::reset_password)) .route("/logout", web::get().to(user::logout)) + .route("/admin", web::get().to(admin::handle_index)) .service( - web::resource("/admin") - .route(web::get().to(admin::index)) - .route(web::post().to(admin::create_user)), + web::scope("/admin") + .route("/create-user", web::post().to(admin::handle_create_user)) + .route( + "/change-password", + web::post().to(admin::handle_change_password), + ), ) .service(actix_files::Files::new("/static", "static/")) }) |
