Skip to content

Commit

Permalink
improve voteDisplay
Browse files Browse the repository at this point in the history
  • Loading branch information
dkhamsing committed Sep 5, 2023
1 parent c1527f7 commit c5603d1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Xcode/FastMDb/Model/Constant.swift
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ struct Constant {
let number = NSNumber(value: count)
guard let formattedValue = Constant.numberFormatter.string(from: number) else { return nil }

return "\(formattedValue) votes"
return "\(formattedValue) vote" + (count == 1 ? "" : "s")
}
}

Expand Down

0 comments on commit c5603d1

Please sign in to comment.