diff options
| author | Jacob Kaplan-Moss <jacob@jacobian.org> | 2009-10-12 16:53:23 +0000 |
|---|---|---|
| committer | Jacob Kaplan-Moss <jacob@jacobian.org> | 2009-10-12 16:53:23 +0000 |
| commit | b30cba4e2bd764cd4f1ec5c0ae1664a078ce967b (patch) | |
| tree | 7db8289f17ae1844847e528539a2c80e3e0df70d | |
| parent | c46ddbf1fc747a910702a348763d7949fba454f0 (diff) | |
Fixed #11993: fixed the the `floatformat` filter on `NaN` values in Python 2.6.3. Thanks, kklimonda.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@11619 bcc190cf-cafb-0310-a4f2-bffc1f526a37
| -rw-r--r-- | django/template/defaultfilters.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/template/defaultfilters.py b/django/template/defaultfilters.py index 47e116cd1a..2957c3d045 100644 --- a/django/template/defaultfilters.py +++ b/django/template/defaultfilters.py @@ -162,7 +162,7 @@ def floatformat(text, arg=-1): try: m = int(d) - d - except (OverflowError, InvalidOperation): + except (ValueError, OverflowError, InvalidOperation): return input_val if not m and p < 0: |
