summaryrefslogtreecommitdiffstats
path: root/src/routes
diff options
context:
space:
mode:
authorSanto Cariotti <santo@dcariotti.me>2022-09-24 13:00:57 +0000
committerSanto Cariotti <santo@dcariotti.me>2022-09-24 13:00:57 +0000
commitbeed53dde27c17b4105c7168285d1deca137e493 (patch)
tree665a41e33439db9d634aac47bf89eb3f37c9a205 /src/routes
parent9549d4689fee866e66478902cba0921c21eb3e25 (diff)
Fix error with multiple path param
Grouped them as tuple
Diffstat (limited to 'src/routes')
-rw-r--r--src/routes/model.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/routes/model.rs b/src/routes/model.rs
index b87258b..7d10061 100644
--- a/src/routes/model.rs
+++ b/src/routes/model.rs
@@ -162,8 +162,7 @@ async fn upload_model_file(
/// The owner or a staffer can delete a model upload
async fn delete_model_file(
claims: Claims,
- Path(model_id): Path<i32>,
- Path(upload_id): Path<i32>,
+ Path((model_id, upload_id)): Path<(i32, i32)>,
) -> Result<StatusCode, AppError> {
let model = match Model::find_by_id(model_id).await {
Ok(model) => model,