Skip to content

Commit

Permalink
authentication
Browse files Browse the repository at this point in the history
  • Loading branch information
udofia2 committed Sep 26, 2020
1 parent c8767c3 commit 864c6d2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion api/middleware/formValidation.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const validation = (check) => {

const loginForm = [
check("email").isEmail(),
check("password").not().notEmpty(),
check("password").not().isEmpty(),
];
return {
regForm,
Expand Down
1 change: 1 addition & 0 deletions api/routes/officer.route.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ const { mySecrete } = require("./../../config/default");
const jwt = require("jsonwebtoken");
const { check, validationResult } = require("express-validator");
const { regForm, loginForm } = require("./../middleware/formValidation")(check);
const auth = require('./../middleware/auth')
const {
officers,
register,
Expand Down

0 comments on commit 864c6d2

Please sign in to comment.