Fixed pre-sort masterlist update never happening.

Closes #274.
This commit is contained in:
WrinklyNinja
2014-09-01 11:44:01 +01:00
parent 70c116c5a2
commit 1846b16eec
+9 -5
View File
@@ -791,11 +791,15 @@ function closeProgressDialog() {
}
}
function sortPlugins(evt) {
Promise.all([function(){
if (loot.settings.updateMasterlist) {
updateMasterlist(evt);
}
}]).then(function(){
var mlistUpdate;
if (loot.settings.updateMasterlist) {
mlistUpdate = updateMasterlist(evt);
} else {
mlistUpdate = new Promise(function(resolve, reject){
resolve('');
});
}
mlistUpdate.then(function(){
updateProgressDialog('Sorting plugins...');
openProgressDialog();
loot.query('sortPlugins').then(JSON.parse).then(function(result){