refactor recovering from cron

This commit is contained in:
Matteo Pagliazzi
2016-05-25 19:58:18 +02:00
parent 31850830a0
commit ed815d4947
3 changed files with 83 additions and 57 deletions

View File

@@ -345,7 +345,7 @@ export let schema = new Schema({
},
lastCron: {type: Date, default: Date.now},
_cronSignature: String, // Private property to avoid double cron
_cronSignature: {type: String, default: 'NOT_RUNNING'}, // Private property used to avoid double cron
// {GROUP_ID: Boolean}, represents whether they have unseen chat messages
newMessages: {type: Schema.Types.Mixed, default: () => {