diff options
author | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2022-01-11 11:09:08 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-11 11:09:08 +0100 |
commit | b111b15c12bb89c49006ea13d20435d2022db23a (patch) | |
tree | 19693b88bfbae41bf580dc4e661497707f585acd /django/utils/dateparse.py | |
parent | fa235004dd1423b129befe847bbf207808ca07ad (diff) | |
download | django-b111b15c12bb89c49006ea13d20435d2022db23a.tar.gz |
Refs #30141 -- Removed unused branch in parse_duration().
Unused since 99fc5dc13c12d874ffc1c8f47a6421494e720b31.
Diffstat (limited to 'django/utils/dateparse.py')
-rw-r--r-- | django/utils/dateparse.py | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/django/utils/dateparse.py b/django/utils/dateparse.py index e2a806c8e8..a137031b3f 100644 --- a/django/utils/dateparse.py +++ b/django/utils/dateparse.py @@ -149,8 +149,6 @@ def parse_duration(value): sign = -1 if kw.pop('sign', '+') == '-' else 1 if kw.get('microseconds'): kw['microseconds'] = kw['microseconds'].ljust(6, '0') - if kw.get('seconds') and kw.get('microseconds') and kw['seconds'].startswith('-'): - kw['microseconds'] = '-' + kw['microseconds'] kw = {k: float(v.replace(',', '.')) for k, v in kw.items() if v is not None} days = datetime.timedelta(kw.pop('days', .0) or .0) if match.re == iso8601_duration_re: |