Skip to content

Commit

Permalink
Dont show bogus date for users without memberTo
Browse files Browse the repository at this point in the history
  • Loading branch information
foodelevator committed Nov 13, 2024
1 parent 9751058 commit 5df50cd
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion templates/admin.templ
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,11 @@ templ MemberList(users []models.User, search string, offset int, more bool, year
<span>{ user.KTHID }</span>
<span>{ user.FirstName } { user.FamilyName }</span>
<span>{ user.YearTag }</span>
<span>{ user.MemberTo.Format(time.DateOnly) }</span>
<span>
if user.MemberTo == (time.Time{}) {
{ user.MemberTo.Format(time.DateOnly) }
}
</span>
</div>
}
for i := len(users); i < 20; i++ {
Expand Down

0 comments on commit 5df50cd

Please sign in to comment.