summaryrefslogtreecommitdiff
path: root/django
diff options
context:
space:
mode:
authorJoshua Phillips <jphillips@imap.cc>2016-04-29 11:44:56 +0100
committerTim Graham <timograham@gmail.com>2016-04-29 10:11:49 -0400
commit4681d65048ca2553895e10c2c492997b0a78ffba (patch)
treecc533591f58a7c2db3dba2337dd6f79223bffa97 /django
parent2f698cd9916cb3d64932248c7114049e02b74fb3 (diff)
Fixed #26557 -- Converted empty strings to None when saving GenericIPAddressField.
Diffstat (limited to 'django')
-rw-r--r--django/db/backends/base/operations.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/django/db/backends/base/operations.py b/django/db/backends/base/operations.py
index 6cd466411a..fe21fd6e58 100644
--- a/django/db/backends/base/operations.py
+++ b/django/db/backends/base/operations.py
@@ -499,7 +499,7 @@ class BaseDatabaseOperations(object):
Transforms a string representation of an IP address into the expected
type for the backend driver.
"""
- return value
+ return value or None
def year_lookup_bounds_for_date_field(self, value):
"""