Commit 66636fbc authored by Bram Schoenmakers's avatar Bram Schoenmakers

Don't mask the imported 'date' class with a 'date' variable

parent 6111e209
......@@ -112,5 +112,5 @@ def translate_key_to_config(p_key):
def humanize_date(p_datetime):
""" Returns a relative date string from a datetime object. """
now = arrow.now()
date = now.replace(day=p_datetime.day, month=p_datetime.month, year=p_datetime.year)
return date.humanize(now).replace('just now', 'today')
_date = now.replace(day=p_datetime.day, month=p_datetime.month, year=p_datetime.year)
return _date.humanize(now).replace('just now', 'today')
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment