From 4a779694c34c90224b7cbbe233f4e7af7e5ac594 Mon Sep 17 00:00:00 2001 From: Girish Ramakrishnan Date: Thu, 23 Jun 2022 12:59:14 -0700 Subject: [PATCH] refresh updates when user enters the app configure view check for updates, if the app has a pending update. this handles two cases: 1. user got a valid subscription. this will make the updates get the manifest field 2. user has not refreshed the ui in a while or updated via cli tool. this will ensure we are not holding to a dangling update --- src/views/app.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/views/app.js b/src/views/app.js index f3b9cae8b..f1c8d8889 100644 --- a/src/views/app.js +++ b/src/views/app.js @@ -2118,6 +2118,11 @@ angular.module('Application').controller('AppController', ['$scope', '$location' ], function (error) { if (error) return Client.error(error); + // check for updates, if the app has a pending update. this handles two cases: + // 1. user got a valid subscription. this will make the updates get the manifest field + // 2. user has not refreshed the ui in a while or updated via cli tool. this will ensure we are not holding to a dangling update + if ($scope.config.update[$scope.app.id]) Client.checkForUpdates(); + done(); }); });