diff --git a/src/api/core/accounts.rs b/src/api/core/accounts.rs index 78e08ba..1c1fae2 100644 --- a/src/api/core/accounts.rs +++ b/src/api/core/accounts.rs @@ -238,6 +238,11 @@ fn post_email(data: JsonUpcase, headers: Headers, conn: DbConn) } #[post("/accounts/delete", data = "")] +fn post_delete_account(data: JsonUpcase, headers: Headers, conn: DbConn) -> EmptyResult { + delete_account(data, headers, conn) +} + +#[delete("/accounts", data = "")] fn delete_account(data: JsonUpcase, headers: Headers, conn: DbConn) -> EmptyResult { let data: PasswordData = data.into_inner().data; let user = headers.user; diff --git a/src/api/core/mod.rs b/src/api/core/mod.rs index 31e4d60..fdff83c 100644 --- a/src/api/core/mod.rs +++ b/src/api/core/mod.rs @@ -23,6 +23,7 @@ pub fn routes() -> Vec { post_email_token, post_email, delete_account, + post_delete_account, revision_date, password_hint, prelogin,