Fixes misleading post time rendering.
This commit is contained in:
parent
7faa8a8dae
commit
9f059bfade
1 changed files with 1 additions and 1 deletions
|
|
@ -86,7 +86,7 @@ when defined(js):
|
||||||
let currentTime = getTime()
|
let currentTime = getTime()
|
||||||
let activityTime = fromUnix(activity)
|
let activityTime = fromUnix(activity)
|
||||||
let duration = currentTime - activityTime
|
let duration = currentTime - activityTime
|
||||||
if duration.days > 300:
|
if currentTime.local().year != activityTime.local().year:
|
||||||
return activityTime.local().format("MMM yyyy")
|
return activityTime.local().format("MMM yyyy")
|
||||||
elif duration.days > 30 and duration.days < 300:
|
elif duration.days > 30 and duration.days < 300:
|
||||||
return activityTime.local().format("MMM dd")
|
return activityTime.local().format("MMM dd")
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue