Commit 1930b899 authored by Anssi Kääriäinen's avatar Anssi Kääriäinen
Browse files

Refix #13844 -- Made FloatField aggregates work on Python 2.6 + Postgres

Fixed a regression introduced in 59a65598.
parent 8a1f439d
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -885,6 +885,8 @@ class BaseDatabaseOperations(object):
        internal_type = field.get_internal_type()
        if internal_type == 'DecimalField':
            return value
        elif internal_type == 'FloatField':
            return float(value)
        elif (internal_type and (internal_type.endswith('IntegerField')
                                 or internal_type == 'AutoField')):
            return int(value)