Consolidate duplicate formatAge functions in feed TUI (gt-798p0)

This commit is contained in:
gastown/crew/joe
2025-12-30 23:24:03 -08:00
committed by Steve Yegge
parent 4178940d39
commit f464f87d5b
2 changed files with 2 additions and 15 deletions
+1 -1
View File
@@ -344,7 +344,7 @@ func (m *Model) renderShortHelp() string {
// formatAge formats a duration as a short age string
func formatAge(d time.Duration) string {
if d < time.Minute {
return fmt.Sprintf("%ds", int(d.Seconds()))
return "just now"
}
if d < time.Hour {
return fmt.Sprintf("%dm", int(d.Minutes()))