TF-2871 Fix validate expire time in swift code

This commit is contained in:
dab246
2024-06-04 16:57:05 +07:00
committed by Dat H. Pham
parent ef159c78c5
commit d2ee12c2ae
9 changed files with 142 additions and 16 deletions
@@ -3,8 +3,8 @@ import Foundation
extension String {
func convertISO8601StringToDate() -> Date? {
let dateFormatter = DateFormatter()
dateFormatter.dateFormat = "yyyy-MM-dd'T'HH:mm:ss.SSS"
dateFormatter.locale = Locale(identifier: "en_US_POSIX")
dateFormatter.dateFormat = CoreUtils.ISO8601_DATE_FORMAT
dateFormatter.locale = Locale(identifier: CoreUtils.EN_US_POSIX_LOCALE)
return dateFormatter.date(from: self)
}