Shrink the precision of 'ago' datetimes so they stay compact

pull/1/head
Danielle McLean 4 years ago
parent 6d7b5db482
commit 6c9b6eb061
Signed by: 00dani
GPG Key ID: 8EB789DDF3ABD240
  1. 2
      lemoncurry/jinja2/ago.py

@ -6,4 +6,4 @@ def ago(dt: datetime) -> str:
# We have to convert the datetime we get to local time first, because ago
# just strips the timezone from a timezone-aware datetime.
dt = dt.astimezone()
return human(dt, past_tense='{}', abbreviate=True)
return human(dt, precision=1, past_tense='{}', abbreviate=True)

Loading…
Cancel
Save