refactor: make version and user_agent &'static str (#18400)

These caused a bunch of unnecessary allocations on each startup.
This commit is contained in:
Bartek Iwańczuk 2023-03-23 23:27:58 +01:00 committed by GitHub
parent edab8f2fd4
commit 275dee60e7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 91 additions and 79 deletions

View file

@ -1746,15 +1746,8 @@ mod tests {
fn create_test_client() -> HttpClient {
HttpClient::from_client(
create_http_client(
"test_client".to_string(),
None,
vec![],
None,
None,
None,
)
.unwrap(),
create_http_client("test_client", None, vec![], None, None, None)
.unwrap(),
)
}