We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 214dd60 commit 455963eCopy full SHA for 455963e
1 file changed
src/search_service.rs
@@ -67,16 +67,12 @@ impl SearchService for LiveSearchService {
67
.context("Error sending HTTP request");
68
let elapsed = start.elapsed();
69
70
- match http_response {
71
- Err(error) => TimedSearchResults {
72
- elapsed,
73
- results: Err(error),
74
- },
75
- Ok(http_response) => TimedSearchResults {
76
77
- results: Self::search_results(http_response),
78
79
- }
+ let results: Result<SearchResults> = match http_response {
+ Ok(response) => Self::search_results(response),
+ Err(error) => Err(error),
+ };
+
+ TimedSearchResults { elapsed, results }
80
}
81
82
0 commit comments