Reload mailer config once admin updates Mailtrain settings
This commit is contained in:
parent
9946f70992
commit
50f6c8d101
6 changed files with 27 additions and 11 deletions
|
@ -87,6 +87,11 @@ router.post('/update', passport.parseForm, passport.csrfProtection, (req, res) =
|
|||
let storeSettings = () => {
|
||||
if (i >= keys.length) {
|
||||
mailer.update();
|
||||
tools.workers.forEach(worker => {
|
||||
worker.send({
|
||||
reload: true
|
||||
});
|
||||
});
|
||||
req.flash('success', 'Settings updated');
|
||||
return res.redirect('/settings');
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue