[Updater > Module] Minor source cleanup
This commit is contained in:
parent
5b83de4bfa
commit
e24a05fc70
1 changed files with 6 additions and 6 deletions
|
@ -262,11 +262,11 @@ const downloadModule = async (name, ver) => {
|
||||||
downloading.done++;
|
downloading.done++;
|
||||||
|
|
||||||
if (downloading.done === downloading.total) {
|
if (downloading.done === downloading.total) {
|
||||||
const successes = downloading.total - downloading.fail;
|
const succeeded = downloading.total - downloading.fail;
|
||||||
log('Modules', 'Done downloads', `[success: ${successes}]`, `[failure: ${downloading.fail}]`);
|
log('Modules', 'Done downloads', `${succeeded}/${downloading.total} success`);
|
||||||
|
|
||||||
events.emit('downloading-modules-finished', {
|
events.emit('downloading-modules-finished', {
|
||||||
succeeded: successes,
|
succeeded,
|
||||||
failed: downloading.fail
|
failed: downloading.fail
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -351,11 +351,11 @@ const finishInstall = (name, ver, success) => {
|
||||||
log('Modules', 'Finished', `${name}@${ver}`, `(${installing.done}/${installing.total})`);
|
log('Modules', 'Finished', `${name}@${ver}`, `(${installing.done}/${installing.total})`);
|
||||||
|
|
||||||
if ((bootstrapping && installing.done === installing.total) || installing.done === downloading.total) {
|
if ((bootstrapping && installing.done === installing.total) || installing.done === downloading.total) {
|
||||||
const successes = installing.total - installing.fail;
|
const succeeded = installing.total - installing.fail;
|
||||||
log('Modules', 'Done installs', `[success: ${successes}]`, `[failure: ${installing.fail}]`);
|
log('Modules', 'Done installs', `${succeeded}/${installing.total} success`);
|
||||||
|
|
||||||
events.emit('installing-modules-finished', {
|
events.emit('installing-modules-finished', {
|
||||||
succeeded: success,
|
succeeded,
|
||||||
failed: installing.fail
|
failed: installing.fail
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue