{
const subject = "vchess.club - notification";
const body = "Hello " + user.name + "!" + `
- ` + message;
+` + message;
sendEmail(params.mail.noreply, user.email, subject, body);
},
tryNotify: function(id, message)
{
UserModel.getOne("id", id, (err,user) => {
- if (!err || !user.notify)
+ if (!!err || !user.notify)
return; //NOTE: error is ignored here
UserModel.notify(user, message);
});