From d3e0c18a4258b89c70e23205645c6dda61f90af0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vojt=C4=9Bch=20Pej=C5=A1a?= Date: Tue, 9 Apr 2019 22:08:14 +0200 Subject: Replace format with to_string() --- src/file_upload.rs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src') diff --git a/src/file_upload.rs b/src/file_upload.rs index 4a0ae1f..534083c 100644 --- a/src/file_upload.rs +++ b/src/file_upload.rs @@ -144,10 +144,7 @@ pub fn upload_file(req: &HttpRequest) -> FutureResponse< .header(header::LOCATION, return_path.to_string()) .finish(), ), - Err(e) => { - let error_description = format!("{}", e); - create_error_response(&error_description, &return_path) - } + Err(e) => create_error_response(&e.to_string(), &return_path), }), ) } -- cgit v1.2.3