I need to check if role must be required or not based on externalVar\'s value. How can I achieve that?
const Joi = require(\'joi\') let externalVar = true m