mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-04 13:38:21 +00:00
better formatting for StarsAmount
This commit is contained in:
parent
ab479ee9f7
commit
0654aa4e52
@ -281,7 +281,7 @@ public struct StarsAmount: Equatable, Comparable, Hashable, Codable, CustomStrin
|
||||
}
|
||||
|
||||
public var stringValue: String {
|
||||
return totalValue.truncatingRemainder(dividingBy: 1) == 0 ? String(format: "%.0f", totalValue) : String(totalValue)
|
||||
return totalValue.truncatingRemainder(dividingBy: 1) == 0 ? String(format: "%.0f", totalValue) : String(format: "%.02f", totalValue)
|
||||
}
|
||||
|
||||
public var totalValue: Double {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user