added lots of validations