diff options
| author | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2017-10-02 14:49:26 +0200 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2017-10-02 08:49:26 -0400 |
| commit | d896809a3ae8dfe45864f284c3ef45bfbb2e5ba1 (patch) | |
| tree | 295f2a149d8657e8988f81f5890aee2474f9ab6d /django/db | |
| parent | f0ffa3f4ea277f9814285085fde20baff60fc386 (diff) | |
Refs #23919 -- Removed unneeded float()/int() calls.
Diffstat (limited to 'django/db')
| -rw-r--r-- | django/db/models/fields/__init__.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/db/models/fields/__init__.py b/django/db/models/fields/__init__.py index b0ab271723..b2e9b18351 100644 --- a/django/db/models/fields/__init__.py +++ b/django/db/models/fields/__init__.py @@ -1631,7 +1631,7 @@ class DurationField(Field): if value is None: return None # Discard any fractional microseconds due to floating point arithmetic. - return int(round(value.total_seconds() * 1000000)) + return round(value.total_seconds() * 1000000) def get_db_converters(self, connection): converters = [] |
