Fixed remaining eslint errors for services/**/*.js
This commit is contained in:
parent
c7ba0235c5
commit
8b74730d08
3 changed files with 8 additions and 8 deletions
|
@ -37,14 +37,14 @@ function spawnProcess(tid, executable, args, outFile, errFile, cwd, uid, gid) {
|
|||
return;
|
||||
}
|
||||
|
||||
privilegeHelpers.ensureMailtrainOwner(outFile, (err) => {
|
||||
privilegeHelpers.ensureMailtrainOwner(outFile, err => {
|
||||
if (err) {
|
||||
log.warn('Executor', 'Cannot change owner of output file of process tid:%s.', tid)
|
||||
log.warn('Executor', 'Cannot change owner of output file of process tid:%s.', tid);
|
||||
}
|
||||
|
||||
privilegeHelpers.ensureMailtrainOwner(errFile, (err) => {
|
||||
privilegeHelpers.ensureMailtrainOwner(errFile, err => {
|
||||
if (err) {
|
||||
log.warn('Executor', 'Cannot change owner of error output file of process tid:%s.', tid)
|
||||
log.warn('Executor', 'Cannot change owner of error output file of process tid:%s.', tid);
|
||||
}
|
||||
|
||||
const options = {
|
||||
|
@ -79,12 +79,12 @@ function spawnProcess(tid, executable, args, outFile, errFile, cwd, uid, gid) {
|
|||
delete processes[tid];
|
||||
log.info('Executor', 'Process tid:%s pid:%s exited with code %s signal %s.', tid, pid, code, signal);
|
||||
|
||||
fs.close(outFd, (err) => {
|
||||
fs.close(outFd, err => {
|
||||
if (err) {
|
||||
log.error('Executor', err);
|
||||
}
|
||||
|
||||
fs.close(errFd, (err) => {
|
||||
fs.close(errFd, err => {
|
||||
if (err) {
|
||||
log.error('Executor', err);
|
||||
}
|
||||
|
|
|
@ -135,7 +135,7 @@ function checkEntries(parent, entries, callback) {
|
|||
if (/\[RSS_ENTRY[\w]*\]/i.test(html)) {
|
||||
html = html.replace(/\[RSS_ENTRY\]/, entry.content); //for backward compatibility
|
||||
Object.keys(entry).forEach(key => {
|
||||
html = html.replace('\[RSS_ENTRY_'+key.toUpperCase()+'\]', entry[key])
|
||||
html = html.replace('[RSS_ENTRY_' + key.toUpperCase() + ']', entry[key]);
|
||||
});
|
||||
} else {
|
||||
html = entry.content + html;
|
||||
|
|
|
@ -29,7 +29,7 @@ let server = new SMTPServer({
|
|||
let user = address.address.split('@').shift();
|
||||
let host = address.address.split('@').pop();
|
||||
|
||||
if (host !== configItems.verpHostname || !/^[a-z0-9_\-]+\.[a-z0-9_\-]+\.[a-z0-9_\-]+$/i.test(user)) {
|
||||
if (host !== configItems.verpHostname || !/^[a-z0-9_-]+\.[a-z0-9_-]+\.[a-z0-9_-]+$/i.test(user)) {
|
||||
err = new Error('Unknown user ' + address.address);
|
||||
err.responseCode = 510;
|
||||
return callback(err);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue