Bug 779497 - Clear addons list inside of async callback. r=wesj

This commit is contained in:
Brian Nicholson 2013-06-03 12:55:46 -07:00
parent e6e2873354
commit 09a251680e

View File

@ -228,12 +228,12 @@ var Addons = {
},
getAddons: function getAddons() {
// Clear all content before filling the addons
let list = document.getElementById("addons-list");
list.innerHTML = "";
let self = this;
AddonManager.getAddonsByTypes(["extension", "theme", "locale"], function(aAddons) {
// Clear all content before filling the addons
let list = document.getElementById("addons-list");
list.innerHTML = "";
for (let i=0; i<aAddons.length; i++) {
let item = self._createItemForAddon(aAddons[i]);
list.appendChild(item);