diff --git a/django/contrib/localflavor/it/forms.py b/django/contrib/localflavor/it/forms.py
index baa56a2..bf02276 100644
a
|
b
|
class ITSocialSecurityNumberField(RegexField):
|
50 | 50 | |
51 | 51 | def clean(self, value): |
52 | 52 | value = super(ITSocialSecurityNumberField, self).clean(value) |
53 | | if value == u'': |
54 | | return value |
| 53 | if value in EMPTY_VALUES: |
| 54 | return u'' |
55 | 55 | value = re.sub('\s', u'', value).upper() |
56 | 56 | try: |
57 | 57 | check_digit = ssn_check_digit(value) |
… |
… |
class ITVatNumberField(Field):
|
71 | 71 | |
72 | 72 | def clean(self, value): |
73 | 73 | value = super(ITVatNumberField, self).clean(value) |
74 | | if value == u'': |
75 | | return value |
| 74 | if value in EMPTY_VALUES: |
| 75 | return u'' |
76 | 76 | try: |
77 | 77 | vat_number = int(value) |
78 | 78 | except ValueError: |