From 4793c343fd3cde3c6282ed0fb38e039b4276de0e Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 16 Feb 2017 19:19:56 +0100 Subject: Add email to pods --- server/middlewares/validators/pods.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'server/middlewares/validators') diff --git a/server/middlewares/validators/pods.js b/server/middlewares/validators/pods.js index b9b30e7a1..0bf4b1844 100644 --- a/server/middlewares/validators/pods.js +++ b/server/middlewares/validators/pods.js @@ -40,7 +40,8 @@ function makeFriends (req, res, next) { } function podsAdd (req, res, next) { - req.checkBody('host', 'Should have an host').isHostValid() + req.checkBody('host', 'Should have a host').isHostValid() + req.checkBody('email', 'Should have an email').isEmail() req.checkBody('publicKey', 'Should have a public key').notEmpty() logger.debug('Checking podsAdd parameters', { parameters: req.body }) -- cgit v1.2.3