mirror of
https://github.com/Hopiu/django.git
synced 2026-03-27 03:10:23 +00:00
parent
7f8a924b45
commit
ef8a339dfb
1 changed files with 0 additions and 2 deletions
|
|
@ -36,8 +36,6 @@ class AreaField(models.FloatField):
|
|||
return getattr(value, self.area_att)
|
||||
|
||||
def from_db_value(self, value, expression, connection, context):
|
||||
if connection.features.interprets_empty_strings_as_nulls and value == '':
|
||||
value = None
|
||||
# If the database returns a Decimal, convert it to a float as expected
|
||||
# by the Python geometric objects.
|
||||
if isinstance(value, Decimal):
|
||||
|
|
|
|||
Loading…
Reference in a new issue