mirror of
https://github.com/django/django.git
synced 2025-11-20 03:30:00 +00:00
Fixed #6014 -- More robust error handling when validating decimal fields.
Thanks, pigletto. git-svn-id: http://code.djangoproject.com/svn/django/trunk@6746 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
7a166f1a1c
commit
29892d02fa
2 changed files with 6 additions and 2 deletions
|
|
@ -323,6 +323,10 @@ Decimal("3.14")
|
|||
Traceback (most recent call last):
|
||||
...
|
||||
ValidationError: [u'Enter a number.']
|
||||
>>> f.clean(u'łąść')
|
||||
Traceback (most recent call last):
|
||||
...
|
||||
ValidationError: [u'Enter a number.']
|
||||
>>> f.clean('1.0 ')
|
||||
Decimal("1.0")
|
||||
>>> f.clean(' 1.0')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue