You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bug with pad options in timeComponents()/timeComponentsSinceNow() in Date/DateInRegion and .string() of TimeInterval. New formatter options struct.
#274
Closed
digidhamu opened this issue
Oct 2, 2016
· 2 comments
malcommac
changed the title
SwiftDate API for converting from Seconds to hh:mm:ss format
Bug with pad options in timeComponents()/timeComponentsSinceNow() in Date/DateInRegion and .string() of TimeInterval. New formatter options struct.
Oct 2, 2016
I am not sure how SwiftDate API works to replace Swift 3 function given below. Basically, this function converts seconds to format hh:mm:ss.
In this case, below Swift 3 code is working fine. But in SwiftDate, not padding Zero e.g. 40:01 rather returns 40:1.
Some more sample
1:01 - 1:1 (no zero)
12:01 -> 12:1 (no zero)
12:20 -> 12:20 (only this works)
Could you please advise anything wrong in using API and even I had tried DateZeroBehaviour as arguments.
Swift 3 Style
SwiftDate Style
The text was updated successfully, but these errors were encountered: