Append Name field to the bottom of email on contact form

This commit is contained in:
Sahat Yalkabov
2013-12-19 13:31:20 -05:00
parent 47e62c39ea
commit 7497f36c03
2 changed files with 4 additions and 4 deletions

View File

@ -66,12 +66,12 @@ exports.getFoursquare = function(req, res) {
* Tumblr API example * Tumblr API example
*/ */
exports.getTumblr = function(req, res) { exports.getTumblr = function(req, res) {
var tumblrToken = _.findWhere(req.user.tokens, { kind: 'tumblr' }); var tumblr = _.findWhere(req.user.tokens, { kind: 'tumblr' });
var client = tumblr.createClient({ var client = tumblr.createClient({
consumer_key: config.tumblr.consumerKey, consumer_key: config.tumblr.consumerKey,
consumer_secret: config.tumblr.consumerSecret, consumer_secret: config.tumblr.consumerSecret,
token: tumblrToken.token, token: tumblr.token,
token_secret: tumblrToken.tokenSecret token_secret: tumblr.tokenSecret
}); });
client.posts('goddess-of-imaginary-light.tumblr.com', { type: 'photo' }, function(err, data) { client.posts('goddess-of-imaginary-light.tumblr.com', { type: 'photo' }, function(err, data) {
res.render('api/tumblr', { res.render('api/tumblr', {

View File

@ -22,7 +22,7 @@ exports.postContact = function(req, res) {
to: sendTo, to: sendTo,
from: from, from: from,
subject: subject, subject: subject,
text: body text: body + '\n\n' + name
}); });
sendgrid.send(email, function(err) { sendgrid.send(email, function(err) {