mirror of
https://github.com/nodemailer/wildduck.git
synced 2025-09-10 23:25:45 +08:00
notify
This commit is contained in:
parent
14b16799fa
commit
b535afeb3d
1 changed files with 4 additions and 0 deletions
4
imap.js
4
imap.js
|
@ -537,6 +537,8 @@ server.onStore = function (path, update, session, callback) {
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.logger.info('UPDATED: %s', updated ? 'YES' : 'NO');
|
||||||
|
|
||||||
if (updated) {
|
if (updated) {
|
||||||
database.collection('messages').findOneAndUpdate({
|
database.collection('messages').findOneAndUpdate({
|
||||||
_id: message._id
|
_id: message._id
|
||||||
|
@ -553,6 +555,8 @@ server.onStore = function (path, update, session, callback) {
|
||||||
message: message._id
|
message: message._id
|
||||||
});
|
});
|
||||||
|
|
||||||
|
this.logger.info('NOTIFY: %s', JSON.stringify(notifyEntries));
|
||||||
|
|
||||||
if (notifyEntries.length > 100) {
|
if (notifyEntries.length > 100) {
|
||||||
setImmediate(() => this.notifier.addEntries(username, path, notifyEntries, processNext));
|
setImmediate(() => this.notifier.addEntries(username, path, notifyEntries, processNext));
|
||||||
notifyEntries = [];
|
notifyEntries = [];
|
||||||
|
|
Loading…
Add table
Reference in a new issue