Skip to content

Commit 5b75617

Browse files
committed
Address clippy lint
1 parent 32aaf46 commit 5b75617

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

src/web/releases.rs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -260,8 +260,7 @@ fn handle_registry_error(err: anyhow::Error) -> Result<SearchResult, SearchError
260260
if let Some(status) = registry_request_error.status() {
261261
if status.is_client_error() || status.is_server_error() {
262262
return Err(SearchError::CratesIo(format!(
263-
"crates.io returned {}: {}",
264-
status, registry_request_error
263+
"crates.io returned {status}: {registry_request_error}"
265264
)));
266265
}
267266
}
@@ -273,10 +272,7 @@ fn handle_registry_error(err: anyhow::Error) -> Result<SearchResult, SearchError
273272
//Error message to gracefully display
274273
fn create_search_error_response(query: String, sort_by: String, error_message: String) -> Search {
275274
Search {
276-
title: format!(
277-
"Search service is not currently available: {}",
278-
error_message
279-
),
275+
title: format!("Search service is not currently available: {error_message}"),
280276
releases: vec![],
281277
search_query: Some(query),
282278
search_sort_by: Some(sort_by),

0 commit comments

Comments
 (0)