add validation to create images