Show published date under main tweets

Fixes #59
This commit is contained in:
Zed
2019-10-08 13:28:57 +02:00
parent dfce77ee98
commit 043f47b11a
4 changed files with 16 additions and 2 deletions

View File

@@ -130,6 +130,9 @@ proc getTime*(tweet: Tweet): string =
proc getRfc822Time*(tweet: Tweet): string =
tweet.time.format("ddd', 'd MMM yyyy HH:mm:ss 'GMT'")
proc getTweetTime*(tweet: Tweet): string =
tweet.time.format("h:mm tt' · 'MMM d', 'YYYY")
proc getLink*(tweet: Tweet | Quote): string =
if tweet.id.len == 0: return
&"/{tweet.profile.username}/status/{tweet.id}"