validations and stylistic changes