summaryrefslogtreecommitdiff
path: root/rust/app/src/routes/category.rs
diff options
context:
space:
mode:
Diffstat (limited to 'rust/app/src/routes/category.rs')
-rw-r--r--rust/app/src/routes/category.rs18
1 files changed, 0 insertions, 18 deletions
diff --git a/rust/app/src/routes/category.rs b/rust/app/src/routes/category.rs
deleted file mode 100644
index ca021fc..0000000
--- a/rust/app/src/routes/category.rs
+++ /dev/null
@@ -1,18 +0,0 @@
-use budgeting_app_core::{
- models::category::Category,
- queries::categories::get_all_categories as get_all_categories_query,
-};
-use rocket::get;
-use rocket::http::Status;
-use rocket::serde::json::Json;
-
-use crate::databases::UserDataDb;
-
-#[get("/category")]
-pub async fn get_all_categories(user_data_db: UserDataDb) -> Result<Json<Vec<Category>>, Status> {
- user_data_db
- .run(get_all_categories_query)
- .await
- .map(Json)
- .map_err(|_| Status { code: 500 })
-}