diff options
| author | Malcolm Tredinnick <malcolm.tredinnick@gmail.com> | 2007-06-10 01:52:56 +0000 |
|---|---|---|
| committer | Malcolm Tredinnick <malcolm.tredinnick@gmail.com> | 2007-06-10 01:52:56 +0000 |
| commit | 6fc10f50b0c9b877fffcad4893056cb91fa66b4f (patch) | |
| tree | b51bf2962318591e351f9c650b9fd0be9fa8710c | |
| parent | 4a1dfe4240f6891bf4f0907b973d3e1575cd7abc (diff) | |
Fixed #4518 -- Added handling of empty strings in typecast_decimal() for
SQLite's benefit. Thanks, Richard House.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5450 bcc190cf-cafb-0310-a4f2-bffc1f526a37
| -rw-r--r-- | django/db/backends/util.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/db/backends/util.py b/django/db/backends/util.py index 18f120b600..81c752e664 100644 --- a/django/db/backends/util.py +++ b/django/db/backends/util.py @@ -91,7 +91,7 @@ def typecast_boolean(s): return str(s)[0].lower() == 't' def typecast_decimal(s): - if s is None: + if s is None or s == '': return None return decimal.Decimal(s) |
