when upgrading is possible rather than throwing an error by reaching
the else branch.

Signed-off-by: Fiona Ebner <f.eb...@proxmox.com>
---
 src/node/APTRepositories.js | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/src/node/APTRepositories.js b/src/node/APTRepositories.js
index 1fb627c..cb08bb6 100644
--- a/src/node/APTRepositories.js
+++ b/src/node/APTRepositories.js
@@ -654,10 +654,12 @@ Ext.define('Proxmox.node.APTRepositories', {
 
                    if (info.kind === 'origin') {
                        infos[path][idx].origin = info.message;
-                   } else if (info.kind === 'warning' ||
-                       (info.kind === 'ignore-pre-upgrade-warning' && 
!repoGrid.majorUpgradeAllowed)
-                   ) {
+                   } else if (info.kind === 'warning') {
                        infos[path][idx].warnings.push(info);
+                   } else if (info.kind === 'ignore-pre-upgrade-warning') {
+                       if (!repoGrid.majorUpgradeAllowed) {
+                           infos[path][idx].warnings.push(info);
+                       }
                    } else {
                        throw 'unknown info';
                    }
-- 
2.39.2



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

Reply via email to