From e857edb69726931adbddf23865db133084ac15af Mon Sep 17 00:00:00 2001 From: Mathias Wagner Date: Tue, 27 Dec 2022 15:07:08 +0100 Subject: [PATCH] Created the authentication validation --- server/validations/auth.js | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 server/validations/auth.js diff --git a/server/validations/auth.js b/server/validations/auth.js new file mode 100644 index 0000000..897368b --- /dev/null +++ b/server/validations/auth.js @@ -0,0 +1,6 @@ +const Joi = require('joi'); + +module.exports.authValidation = Joi.object({ + username: Joi.string().min(5).max(25).required(), + password: Joi.string().min(6).required() +}); \ No newline at end of file