mirror of
https://gitlab.silvrtree.co.uk/martind2000/old-silvrgit.git
synced 2025-01-10 22:05:07 +00:00
updated today.js
This commit is contained in:
parent
e6c9afa058
commit
5d0d3ad34a
@ -2,7 +2,7 @@
|
||||
* Created by marti on 30/01/2016.
|
||||
*/
|
||||
var http = require('http'), request = require('request'), cheerio = require('cheerio'), Forecast = require('forecast.io'), util = require('util'), UltraSES = require('ultrases'), cron = require('node-cron');
|
||||
var jade = require('jade'), _ = require('lodash'), dateFormat = require('dateformat');
|
||||
var jade = require('jade'), _ = require('lodash');
|
||||
var jsonfile = require('jsonfile');
|
||||
|
||||
var todayCache = {
|
||||
@ -203,15 +203,12 @@ module.exports = {
|
||||
;
|
||||
|
||||
function sendEmail() {
|
||||
|
||||
var now = new Date();
|
||||
|
||||
var email = {
|
||||
to: 'martind2000@gmail.com',
|
||||
subject: 'Today - ' + dateFormat(now, "dddd, mmmm dS, yyyy")
|
||||
subject: 'Today'
|
||||
};
|
||||
|
||||
var template = {file: 'lib/jade/today.jade', locals: todayCache};
|
||||
var template = {file: 'jade/today.jade', locals: todayCache};
|
||||
mailer.sendTemplate(email, template, function (err) {
|
||||
if (err) throw err;
|
||||
console.log('compiled template email sent');
|
||||
|
Loading…
Reference in New Issue
Block a user