mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-08-21 12:55:22 +00:00
Updates notification (#3119)
Hi, Like some default modules, I propose to send an `UPDATES` notification in an array with the git information of these modules This allows developers to create their own auto-update system (which I've been using in my case since 3 years, with automatic things) Of course, for security reasons `MagicMirror` is excluded --------- Co-authored-by: bugsounet <bugsounet@bugsounet.fr>
This commit is contained in:
committed by
GitHub
parent
b7371538bc
commit
e985e99036
@@ -44,6 +44,11 @@ module.exports = NodeHelper.create({
|
||||
this.sendSocketNotification("STATUS", repo);
|
||||
}
|
||||
|
||||
if (this.config.sendUpdatesNotifications) {
|
||||
const updates = await this.gitHelper.checkUpdates();
|
||||
if (updates.length) this.sendSocketNotification("UPDATES", updates);
|
||||
}
|
||||
|
||||
this.scheduleNextFetch(this.config.updateInterval);
|
||||
},
|
||||
|
||||
|
Reference in New Issue
Block a user