Django

Code

Changeset 5930

Show
Ignore:
Timestamp:
08/18/07 01:13:15 (1 year ago)
Author:
mtredinnick
Message:

Fixed #5166 -- Fixed a validation problem in one of the examples. Thanks, o.ekanem@gmail.com.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/docs/newforms.txt

    r5888 r5930  
    14201420    class MultiEmailField(forms.Field): 
    14211421        def clean(self, value): 
     1422            if not value: 
     1423                raise forms.ValidationError('Enter at least one e-mail address.') 
    14221424            emails = value.split(',') 
    14231425            for email in emails: 
    14241426                if not is_valid_email(email): 
    14251427                    raise forms.ValidationError('%s is not a valid e-mail address.' % email) 
    1426             if not emails: 
    1427                 raise forms.ValidationError('Enter at least one e-mail address.') 
    14281428            return emails 
    14291429