chore(deprecated api): log a warning on serverside if a deprecated route is still used

This commit is contained in:
Edouard Vanbelle
2026-05-29 12:54:09 +02:00
parent d88b3a313f
commit 6e30353c4b
4 changed files with 9 additions and 5 deletions
@@ -490,6 +490,7 @@ pub async fn list_folder_contents(
auth_user: AuthUser,
path: Path<String>,
) -> axum::response::Response {
tracing::warn!("Deprecated endpoint called: GET /api/folders/{{id}}/contents — use GET /api/folders/{{id}}/resources?resource_types=folder instead");
FolderHandler::list_folder_contents_impl(state, auth_user, path).await
}
@@ -533,6 +534,7 @@ pub async fn list_folder_contents_paginated(
path: Path<String>,
pagination: Query<PaginationRequestDto>,
) -> axum::response::Response {
tracing::warn!("Deprecated endpoint called: GET /api/folders/{{id}}/contents/paginated — use GET /api/folders/{{id}}/resources instead");
FolderHandler::list_folder_contents_paginated_impl(state, auth_user, path, pagination).await
}