diff options
Diffstat (limited to 'django/utils/datetime_safe.py')
| -rw-r--r-- | django/utils/datetime_safe.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/django/utils/datetime_safe.py b/django/utils/datetime_safe.py index 817ddcf0fa..2792b48a26 100644 --- a/django/utils/datetime_safe.py +++ b/django/utils/datetime_safe.py @@ -95,10 +95,10 @@ def strftime(dt, fmt): # 6 years to get into the 28-year repeat cycle delta = 2000 - year off = 6 * (delta // 100 + delta // 400) - year = year + off + year += off # Move to around the year 2000 - year = year + ((2000 - year) // 28) * 28 + year += ((2000 - year) // 28) * 28 timetuple = dt.timetuple() s1 = time.strftime(fmt, (year,) + timetuple[1:]) sites1 = _findall(s1, str(year)) |
