Add validation for images