diff options
| author | zauddelig <zauddelig@gmail.com> | 2015-06-02 11:08:41 +0200 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2015-06-02 12:42:31 -0400 |
| commit | 7f92b6e576daace8051785dc046aca00bdccfed4 (patch) | |
| tree | 48bfb39afe875b4987df89a902ecd8371fdaadf0 /django/utils | |
| parent | 9d83de8ff3b835603fe09e8842529c9810bc1dcd (diff) | |
[1.8.x] Fixed #24897 -- Allowed using choices longer than 1 day with DurationField
Backport of 262d4db8c4c849b0fdd84550fb96472446cf90df from master
Diffstat (limited to 'django/utils')
| -rw-r--r-- | django/utils/dateparse.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/utils/dateparse.py b/django/utils/dateparse.py index a3c760e8fb..30a96f818e 100644 --- a/django/utils/dateparse.py +++ b/django/utils/dateparse.py @@ -29,7 +29,7 @@ datetime_re = re.compile( standard_duration_re = re.compile( r'^' - r'(?:(?P<days>-?\d+) )?' + r'(?:(?P<days>-?\d+) (days?, )?)?' r'((?:(?P<hours>\d+):)(?=\d+:\d+))?' r'(?:(?P<minutes>\d+):)?' r'(?P<seconds>\d+)' |
