added joi validation