]> git.proxmox.com Git - proxmox.git/commitdiff
http: concat! user agent instead of format!
authorWolfgang Bumiller <w.bumiller@proxmox.com>
Mon, 15 Jan 2024 10:17:57 +0000 (11:17 +0100)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Mon, 15 Jan 2024 10:17:57 +0000 (11:17 +0100)
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
proxmox-http/src/client/sync.rs

index 119d8d6837c6a8aa84f9b9ff88121e71b53fe161..195ce98fb48cfb8caf28bdf8795e56d8202874d7 100644 (file)
@@ -21,8 +21,8 @@ impl Client {
     fn agent(&self) -> Result<ureq::Agent, Error> {
         let mut builder = ureq::AgentBuilder::new();
 
-        builder = builder.user_agent(self.options.user_agent.as_deref().unwrap_or(&format!(
-            "proxmox-sync-http-client/{}",
+        builder = builder.user_agent(self.options.user_agent.as_deref().unwrap_or(concat!(
+            "proxmox-sync-http-client/",
             env!("CARGO_PKG_VERSION")
         )));