This commit is contained in:
Andris Reinman 2018-04-28 22:54:38 +03:00
parent cc11785cc6
commit 2510495ecf
2 changed files with 8 additions and 7 deletions

View file

@ -138,7 +138,9 @@ class DkimHandler {
} else if (options._id && tools.isId(options._id)) {
query._id = new ObjectID(options._id);
} else {
return setImmediate(() => callback(new Error('Invalid input')));
let err = new Error('Invalid or unknown DKIM key');
err.code = 'KeyNotFound';
return setImmediate(() => callback(err));
}
this.database.collection('dkim').findOne(query, (err, dkimData) => {
@ -199,7 +201,9 @@ class DkimHandler {
} else if (options._id && tools.isId(options._id)) {
query._id = new ObjectID(options._id);
} else {
return setImmediate(() => callback(new Error('Invalid input')));
let err = new Error('Invalid or unknown DKIM key');
err.code = 'KeyNotFound';
return setImmediate(() => callback(err));
}
// delete address from email address registry

View file

@ -1,6 +1,6 @@
{
"name": "wildduck",
"version": "1.0.117",
"version": "1.1.0",
"description": "IMAP/POP3 server built with Node.js and MongoDB",
"main": "server.js",
"scripts": {
@ -9,10 +9,7 @@
"apidoc": "apidoc -i lib/api/ -o docs/",
"show": "NODE_CONFIG_ONLY=true node server.js"
},
"keywords": [
"imap",
"mail server"
],
"keywords": ["imap", "mail server"],
"author": "Andris Reinman",
"license": "EUPL-1.1+",
"devDependencies": {