How do i fix the code below?

You’ll probably need to use schema.validate instead of Joi.validate as explained here.