From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <pdm-devel-bounces@lists.proxmox.com>
Received: from firstgate.proxmox.com (firstgate.proxmox.com [IPv6:2a01:7e0:0:424::9])
	by lore.proxmox.com (Postfix) with ESMTPS id 420B51FF173
	for <inbox@lore.proxmox.com>; Mon, 13 Jan 2025 15:28:17 +0100 (CET)
Received: from firstgate.proxmox.com (localhost [127.0.0.1])
	by firstgate.proxmox.com (Proxmox) with ESMTP id 696C5EA5;
	Mon, 13 Jan 2025 15:28:00 +0100 (CET)
From: Maximiliano Sandoval <m.sandoval@proxmox.com>
To: pdm-devel@lists.proxmox.com
Date: Mon, 13 Jan 2025 15:27:11 +0100
Message-Id: <20250113142725.523748-1-m.sandoval@proxmox.com>
X-Mailer: git-send-email 2.39.5
MIME-Version: 1.0
X-SPAM-LEVEL: Spam detection results:  0
 AWL 0.103 Adjusted score from AWL reputation of From: address
 BAYES_00                 -1.9 Bayes spam probability is 0 to 1%
 DMARC_MISSING             0.1 Missing DMARC policy
 KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment
 RCVD_IN_VALIDITY_CERTIFIED_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to
 Validity was blocked. See
 https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more
 information.
 RCVD_IN_VALIDITY_RPBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to
 Validity was blocked. See
 https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more
 information.
 RCVD_IN_VALIDITY_SAFE_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to
 Validity was blocked. See
 https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more
 information.
 SPF_HELO_NONE           0.001 SPF: HELO does not publish an SPF Record
 SPF_PASS               -0.001 SPF: sender matches SPF record
Subject: [pdm-devel] [PATCH proxmox-yew-comp 01/15] remove needless borrows
X-BeenThere: pdm-devel@lists.proxmox.com
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Proxmox Datacenter Manager development discussion
 <pdm-devel.lists.proxmox.com>
List-Unsubscribe: <https://lists.proxmox.com/cgi-bin/mailman/options/pdm-devel>, 
 <mailto:pdm-devel-request@lists.proxmox.com?subject=unsubscribe>
List-Archive: <http://lists.proxmox.com/pipermail/pdm-devel/>
List-Post: <mailto:pdm-devel@lists.proxmox.com>
List-Help: <mailto:pdm-devel-request@lists.proxmox.com?subject=help>
List-Subscribe: <https://lists.proxmox.com/cgi-bin/mailman/listinfo/pdm-devel>, 
 <mailto:pdm-devel-request@lists.proxmox.com?subject=subscribe>
Reply-To: Proxmox Datacenter Manager development discussion
 <pdm-devel@lists.proxmox.com>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: pdm-devel-bounces@lists.proxmox.com
Sender: "pdm-devel" <pdm-devel-bounces@lists.proxmox.com>

Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
 src/apt_package_manager.rs        | 2 +-
 src/apt_repositories.rs           | 6 +++---
 src/configuration/network_edit.rs | 2 +-
 src/configuration/network_view.rs | 2 +-
 src/form/mod.rs                   | 2 +-
 src/rrd_graph_new.rs              | 2 +-
 6 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/apt_package_manager.rs b/src/apt_package_manager.rs
index 6e0d677..5171d81 100644
--- a/src/apt_package_manager.rs
+++ b/src/apt_package_manager.rs
@@ -237,7 +237,7 @@ impl LoadableComponent for ProxmoxAptPackageManager {
     ) -> Option<Html> {
         match view_state {
             ViewState::ShowChangelog(package) => {
-                Some(self.create_show_changelog_dialog(ctx, &package))
+                Some(self.create_show_changelog_dialog(ctx, package))
             }
         }
     }
diff --git a/src/apt_repositories.rs b/src/apt_repositories.rs
index c92665e..bf308bd 100644
--- a/src/apt_repositories.rs
+++ b/src/apt_repositories.rs
@@ -213,7 +213,7 @@ fn update_status_store(
                 if check_mixed_suites
                     && repo.enabled
                     && repo.types.contains(&APTRepositoryPackageType::Deb)
-                    && controlled_origin.contains(&(&path, index))
+                    && controlled_origin.contains(&(path, index))
                 {
                     mixed_suites = true;
                 }
@@ -474,7 +474,7 @@ impl LoadableComponent for ProxmoxAptRepositories {
                     update_status_store(
                         props.product,
                         &self.status_store,
-                        &config,
+                        config,
                         &self.standard_repos,
                         active_subscription,
                     );
@@ -503,7 +503,7 @@ impl LoadableComponent for ProxmoxAptRepositories {
                 self.standard_repos = standard_repos.clone();
 
                 self.validate_standard_repo = ValidateFn::new(move |(repo, _): &(String, _)| {
-                    let (_, _, enabled) = standard_repo_info(&standard_repos, &repo);
+                    let (_, _, enabled) = standard_repo_info(&standard_repos, repo);
                     if enabled {
                         Err(Error::msg(tr!("Already configured")))
                     } else {
diff --git a/src/configuration/network_edit.rs b/src/configuration/network_edit.rs
index 5629da9..010dc30 100644
--- a/src/configuration/network_edit.rs
+++ b/src/configuration/network_edit.rs
@@ -61,7 +61,7 @@ async fn create_item(
         }
     }
 
-    data["type"] = serde_json::to_value(&interface_type).unwrap();
+    data["type"] = serde_json::to_value(interface_type).unwrap();
 
     crate::http_post("/nodes/localhost/network", Some(data)).await
 }
diff --git a/src/configuration/network_view.rs b/src/configuration/network_view.rs
index 5cc0d68..c56d97c 100644
--- a/src/configuration/network_view.rs
+++ b/src/configuration/network_view.rs
@@ -36,7 +36,7 @@ async fn load_interfaces() -> Result<(Vec<Interface>, String), Error> {
 async fn delete_interface(key: Key) -> Result<(), Error> {
     let url = format!(
         "/nodes/localhost/network/{}",
-        percent_encode_component(&*key)
+        percent_encode_component(&key)
     );
     crate::http_delete(&url, None).await?;
     Ok(())
diff --git a/src/form/mod.rs b/src/form/mod.rs
index 9661c28..0b9d8a9 100644
--- a/src/form/mod.rs
+++ b/src/form/mod.rs
@@ -16,7 +16,7 @@ fn format_property(name: &str, part: &str) -> String {
 /// to expose a property to the UI, simply add a hidden field to the form.
 pub fn flatten_property_string(data: &mut Value, name: &str, schema: &'static Schema) {
     if let Some(prop_str) = data[name].as_str() {
-        if let Ok(Value::Object(map)) = schema.parse_property_string(&prop_str) {
+        if let Ok(Value::Object(map)) = schema.parse_property_string(prop_str) {
             for (part, v) in map {
                 data[format_property(name, &part)] = v;
             }
diff --git a/src/rrd_graph_new.rs b/src/rrd_graph_new.rs
index 26a19b6..2d1db13 100644
--- a/src/rrd_graph_new.rs
+++ b/src/rrd_graph_new.rs
@@ -488,7 +488,7 @@ impl PwtRRDGraph {
                 &serie1_data[serie1_start..serie1_end],
             )
         } else {
-            (&time_data, &serie0_data, &serie1_data)
+            (time_data, serie0_data, serie1_data)
         }
     }
 
-- 
2.39.5



_______________________________________________
pdm-devel mailing list
pdm-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pdm-devel