SwiftDate
SwiftDate copied to clipboard
"15:30:00".toDate() returns nil (just a warning, not actually the library bug (although might be targeted design wise))
Default constructor of DateInRegion defaults to using SwiftDate.defaultRegion which is Region.UTC, that in turn uses Locale.autoupdatingCurrent as its default locale. As the result if device is set to display time in 12h format and region is set to United Kingdom "15:30:00".toDate() returns nil. Not sure what's up with GB and 12h format locale, but results are really nasty. Workaround might be defaulting to en_US_POSIX locale.