Skip to content

Commit

Permalink
Merge pull request #23 from semihbkgr/fix-print-nil
Browse files Browse the repository at this point in the history
Fix printing '<nil>' in table cell
  • Loading branch information
applejag committed Aug 18, 2023
2 parents cf22f01 + 91012b6 commit 825d2fa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/table/row.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,9 @@ func renderColumn(value any) string {
dur := time.Since(value)
return duration.HumanDuration(dur)
default:
if value == nil {
return ""
}
return fmt.Sprint(value)
}
}

0 comments on commit 825d2fa

Please sign in to comment.