From 2f6dc8743e559383d743a57a835575f5753b0668 Mon Sep 17 00:00:00 2001 From: Vincent Petry Date: Thu, 2 Jul 2015 17:15:14 +0200 Subject: Fix global app list state --- settings/js/apps.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'settings') diff --git a/settings/js/apps.js b/settings/js/apps.js index 7849e1b7573..d1de3d727c0 100644 --- a/settings/js/apps.js +++ b/settings/js/apps.js @@ -86,11 +86,12 @@ OC.Settings.Apps = OC.Settings.Apps || { }), { type:'GET', success: function (apps) { - var appList = _.map(_.indexBy(apps.apps, 'id'), function(app) { + var appListWithIndex = _.indexBy(apps.apps, 'id'); + OC.Settings.Apps.State.apps = appListWithIndex; + var appList = _.map(appListWithIndex, function(app) { // default values for missing fields return _.extend({level: 0}, app); }); - OC.Settings.Apps.State.apps = appList; var source = $("#app-template").html(); var template = Handlebars.compile(source); -- cgit v1.2.3