Skip to content

Commit

Permalink
Fixing implicit type in test
Browse files Browse the repository at this point in the history
  • Loading branch information
jake-danton committed Apr 21, 2015
1 parent a00d357 commit 7fa5d15
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions express-validator/express-validator-tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ var app = express()

app.use(expressValidator());

app.post('/:urlparam', function(req: expressValidator.ValidatedRequest, res) {
app.post('/:urlparam', function(req: expressValidator.ValidatedRequest, res: express.Response) {

// checkBody only checks req.body; none of the other req parameters
// Similarly checkParams only checks in req.params (URL params) and
Expand All @@ -27,7 +27,7 @@ app.post('/:urlparam', function(req: expressValidator.ValidatedRequest, res) {

var errors = req.validationErrors();
if (errors) {
res.send('There have been validation errors: ' + util.inspect(errors), 400);
res.status(400).send('There have been validation errors: ' + util.inspect(errors));
return;
}
res.json({
Expand Down

0 comments on commit 7fa5d15

Please sign in to comment.