]> git.proxmox.com Git - proxmox-backup.git/commitdiff
adapt to proxmox-apt change
authorFabian Grünbichler <f.gruenbichler@proxmox.com>
Thu, 21 Jul 2022 10:05:49 +0000 (12:05 +0200)
committerFabian Grünbichler <f.gruenbichler@proxmox.com>
Mon, 25 Jul 2022 08:03:44 +0000 (10:03 +0200)
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Cargo.toml
src/api2/node/apt.rs

index d0df116ab816533404fe8e492e63edc0851aedab..4b3ee0770228b988cb681dc8907d101268d440ec 100644 (file)
@@ -111,7 +111,7 @@ proxmox-compression = "0.1"
 
 
 proxmox-acme-rs = "0.4"
-proxmox-apt = "0.8.0"
+proxmox-apt = "0.9.0"
 proxmox-async = "0.4"
 proxmox-openid = "0.9.0"
 
index 0bb1b3addbf7b92107a118202f37464e29821540..2e885ecbc6e8f3526519b239200c606ff15ca029 100644 (file)
@@ -554,7 +554,7 @@ pub fn add_repository(handle: APTRepositoryHandle, digest: Option<String>) -> Re
         );
     }
 
-    if let Some(file) = files.iter_mut().find(|file| file.path == path) {
+    if let Some(file) = files.iter_mut().find(|file| file.path.as_ref() == Some(&path)) {
         file.repositories.push(repo);
 
         file.write()?;
@@ -622,7 +622,7 @@ pub fn change_repository(
         bail!("unable to parse file {} - {}", error.path, error.error);
     }
 
-    if let Some(file) = files.iter_mut().find(|file| file.path == path) {
+    if let Some(file) = files.iter_mut().find(|file| file.path.as_ref() == Some(&path)) {
         if let Some(repo) = file.repositories.get_mut(index) {
             if let Some(enabled) = enabled {
                 repo.set_enabled(enabled);