mirror of
https://github.com/nodemailer/wildduck.git
synced 2024-11-10 17:47:07 +08:00
21 lines
509 B
JavaScript
21 lines
509 B
JavaScript
'use strict';
|
|
|
|
const config = require('wild-config');
|
|
const db = require('./db');
|
|
const Maildropper = require('./maildropper');
|
|
|
|
let maildropper;
|
|
|
|
module.exports = (options, callback) => {
|
|
maildropper =
|
|
maildropper ||
|
|
new Maildropper({
|
|
db,
|
|
zone: config.sender.zone,
|
|
collection: config.sender.collection,
|
|
gfs: config.sender.gfs,
|
|
loopSecret: config.sender.loopSecret
|
|
});
|
|
|
|
return maildropper.push(options, callback);
|
|
};
|