remember instead of validate_image_type use is_image_type_valid?