AMBARI-12868. Improve calls to the localStorage (onechiporenko)

Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/6fc31441
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/6fc31441
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/6fc31441

Branch: refs/heads/trunk
Commit: 6fc31441476879fb668bc47f6d0c00d18cba4fd7
Parents: f4286d5
Author: Oleg Nechiporenko <[email protected]>
Authored: Fri Aug 28 12:53:36 2015 +0300
Committer: Oleg Nechiporenko <[email protected]>
Committed: Fri Aug 28 13:10:41 2015 +0300

----------------------------------------------------------------------
 .../app/controllers/main/admin/stack_and_upgrade_controller.js   | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/6fc31441/ambari-web/app/controllers/main/admin/stack_and_upgrade_controller.js
----------------------------------------------------------------------
diff --git 
a/ambari-web/app/controllers/main/admin/stack_and_upgrade_controller.js 
b/ambari-web/app/controllers/main/admin/stack_and_upgrade_controller.js
index fa5b479..ddca7f1 100644
--- a/ambari-web/app/controllers/main/admin/stack_and_upgrade_controller.js
+++ b/ambari-web/app/controllers/main/admin/stack_and_upgrade_controller.js
@@ -163,7 +163,9 @@ App.MainAdminStackAndUpgradeController = 
Em.Controller.extend(App.LocalStorage,
   initDBProperties: function () {
     var props = this.getDBProperties(this.get('wizardStorageProperties'));
     Em.keys(props).forEach(function (k) {
-      this.set(k, props[k]);
+      if (props[k]) {
+        this.set(k, props[k]);
+      }
     }, this);
   },
 

Reply via email to