diff --git a/ef-api/controllers/user.js b/ef-api/controllers/user.js index 215ecc7..55c19b2 100644 --- a/ef-api/controllers/user.js +++ b/ef-api/controllers/user.js @@ -11,6 +11,10 @@ const secret = process.env.SECRET_KEY; export const signup = async (req, res) => { const { title, email, password, firstName, middleName, lastName, termsconditions, userType } = req.body; + function generateRandomNumber() { + return Math.floor(Math.random() * 90000) + 10000; + } + try { // Check if user already exists const oldUser = await UserModal.findOne({ email });