mirror of
https://github.com/nodemailer/wildduck.git
synced 2025-01-04 07:02:45 +08:00
notify
This commit is contained in:
parent
72512fbce7
commit
14b16799fa
1 changed files with 1 additions and 1 deletions
|
@ -92,6 +92,7 @@ class ImapNotifier extends EventEmitter {
|
||||||
* @param {Function} callback Runs once the entry is either stored or an error occurred
|
* @param {Function} callback Runs once the entry is either stored or an error occurred
|
||||||
*/
|
*/
|
||||||
addEntries(username, path, entries, callback) {
|
addEntries(username, path, entries, callback) {
|
||||||
|
this.logger.info('NOTIFY "%s":"%s" %s', username, path, JSON.stringify(entries));
|
||||||
if (entries && !Array.isArray(entries)) {
|
if (entries && !Array.isArray(entries)) {
|
||||||
entries = [entries];
|
entries = [entries];
|
||||||
} else if (!entries || !entries.length) {
|
} else if (!entries || !entries.length) {
|
||||||
|
@ -100,7 +101,6 @@ class ImapNotifier extends EventEmitter {
|
||||||
|
|
||||||
entries.forEach(entry => {
|
entries.forEach(entry => {
|
||||||
entry.created = new Date();
|
entry.created = new Date();
|
||||||
this.logger.info('NOTIFY "%s":"%s" %s', username, path, JSON.stringify(entry));
|
|
||||||
});
|
});
|
||||||
|
|
||||||
this.database.collection('mailboxes').findOneAndUpdate({
|
this.database.collection('mailboxes').findOneAndUpdate({
|
||||||
|
|
Loading…
Reference in a new issue