From 85722a84927e227dabcf5b28b13e8f284abbcdb9 Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Sat, 19 Jan 2019 16:42:43 +0100 Subject: [PATCH] api/router.rs: rename ApiUploadMethod to ApiAsyncMethod We can use this for uploads and downloads ... --- src/server/rest.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/server/rest.rs b/src/server/rest.rs index 1bd724eb..74cf1049 100644 --- a/src/server/rest.rs +++ b/src/server/rest.rs @@ -178,8 +178,8 @@ fn handle_sync_api_request( Box::new(resp) } -fn handle_upload_api_request( - info: &'static ApiUploadMethod, +fn handle_async_api_request( + info: &'static ApiAsyncMethod, formatter: &'static OutputFormatter, parts: Parts, req_body: Body, @@ -405,8 +405,8 @@ pub fn handle_request(api: Arc, req: Request) -> BoxFut { MethodDefinition::Simple(api_method) => { return handle_sync_api_request(api_method, formatter, parts, body, uri_param); } - MethodDefinition::Upload(upload_method) => { - return handle_upload_api_request(upload_method, formatter, parts, body, uri_param); + MethodDefinition::Async(async_method) => { + return handle_async_api_request(async_method, formatter, parts, body, uri_param); } } }