[Answered ]-Django 1.7: allow_empty_file not working in ImageField

1👍

It should be

pic_upload = forms.ImageField(required=False)

blank=True is used in model definition, not forms.

👤levi

1👍

You are getting the error when you put blank=True because it is a form field, not a model field. Use required=False instead.

Leave a comment