fixed displaying errors on the plugins page

This commit is contained in:
antelle 2019-09-29 12:35:47 +02:00
parent be5dcba4c6
commit fd51fdddb3
2 changed files with 26 additions and 12 deletions

View File

@ -33,22 +33,33 @@ const PluginGallery = {
this.logger.error('Network error loading plugins');
resolve();
});
}).then(data => {
return this.verifySignature(data).then(gallery => {
})
.then(data => {
this.loading = false;
this.loadError = !gallery;
if (gallery) {
this.logger.debug(
`Loaded ${gallery.plugins.length} plugins`,
this.logger.ts(ts)
);
this.gallery = gallery;
this.saveGallery(gallery);
if (!data) {
this.loadError = true;
Events.emit('plugin-gallery-load-complete');
return;
}
return this.verifySignature(data).then(gallery => {
this.loadError = !gallery;
if (gallery) {
this.logger.debug(
`Loaded ${gallery.plugins.length} plugins`,
this.logger.ts(ts)
);
this.gallery = gallery;
this.saveGallery(gallery);
}
Events.emit('plugin-gallery-load-complete');
return gallery;
});
})
.catch(e => {
this.loadError = true;
this.logger.error('Error loading plugin gallery', e);
Events.emit('plugin-gallery-load-complete');
return gallery;
});
});
},
verifySignature(gallery) {

View File

@ -1,5 +1,8 @@
Release notes
-------------
##### v1.11.4 (TBD)
`-` fixed displaying errors on the plugins page
##### v1.11.3 (2019-09-29)
`-` fix #1275: starting the app after closing on macOS
`-` fix #1276 GDrive connection issues