Fixed a typo and added form placeholders

This commit is contained in:
Sahat Yalkabov
2014-02-11 08:24:04 -05:00
parent c5a73443d6
commit 6b7c68c1c6
2 changed files with 5 additions and 5 deletions

View File

@ -464,7 +464,7 @@ exports.postVenmo = function(req, res, next) {
if (validator.isEmail(req.body.user)) {
formData.email = req.body.user;
} else if (validator.isNumberic(req.body.user) &&
} else if (validator.isNumeric(req.body.user) &&
validator.isLength(req.body.user, 10, 11)) {
formData.phone = req.body.user;
} else {
@ -472,7 +472,7 @@ exports.postVenmo = function(req, res, next) {
}
// Send money
request.post('https://sandbox-api.venmo.com/v1/payments', { form: formData }, function(err, request, body) {
request.post('https://api.venmo.com/v1/payments', { form: formData }, function(err, request, body) {
if (err) return next(err);
if (request.statusCode !== 200) {
req.flash('errors', { msg: JSON.parse(body).error.message });