From bf213ab7efbb8c19d1242902a2dcb64dc7ce98de Mon Sep 17 00:00:00 2001 From: Byung jin Date: Fri, 12 May 2023 23:02:43 +0900 Subject: [PATCH 1/3] =?UTF-8?q?=E2=9A=A1=EF=B8=8F=20::=20DateFormat=20case?= =?UTF-8?q?=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Modules/XDateUtil/Sources/DateFormat.swift | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Modules/XDateUtil/Sources/DateFormat.swift b/Modules/XDateUtil/Sources/DateFormat.swift index 913e24e7..3fd3a747 100644 --- a/Modules/XDateUtil/Sources/DateFormat.swift +++ b/Modules/XDateUtil/Sources/DateFormat.swift @@ -1,8 +1,10 @@ import Foundation public enum DateFormat: String { + /// yyyy-MM-dd'T'HH:mm:ss.SSSSSSSSS + case fullDateWithMilliSecondTime = "yyyy-MM-dd'T'HH:mm:ss.SSSSSSSSS" /// yyyy-MM-dd'T'HH:mm:ss - case fullDateWithTime = "yyyy-MM-dd'T'HH:mm:ss.SSSSSSSSS" + case fullDateWithTime = "yyyy-MM-dd'T'HH:mm:ss" /// yyyy-MM-dd case fullDate = "yyyy-MM-dd" /// yyyy From 7ddab2ce4ed34a25f8037cd886834aeef3ffa41e Mon Sep 17 00:00:00 2001 From: Byung jin Date: Fri, 12 May 2023 23:03:10 +0900 Subject: [PATCH 2/3] =?UTF-8?q?=E2=9A=A1=EF=B8=8F=20::=20toDate=ED=95=A8?= =?UTF-8?q?=EC=88=98=20=EC=98=A4=EB=A5=98=EC=8B=9C=20=EB=A1=9C=EA=B7=B8=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Modules/XDateUtil/Sources/StringToDate.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/Modules/XDateUtil/Sources/StringToDate.swift b/Modules/XDateUtil/Sources/StringToDate.swift index 5f0bfbfb..e25daf89 100644 --- a/Modules/XDateUtil/Sources/StringToDate.swift +++ b/Modules/XDateUtil/Sources/StringToDate.swift @@ -4,6 +4,7 @@ public extension String { func toDate(format: DateFormat) -> Date { XDateFormatter.shared.dateFormat = format.rawValue guard let returnDate = XDateFormatter.shared.date(from: self) else { + print("toDate Error: Date로 format하려는 데이터의 형식이 DateFormat과 일치하지 않습니다.") return Date() } return returnDate From b66cbedebd7e1c1b047ec8eef8f1a597214c9321 Mon Sep 17 00:00:00 2001 From: Byung jin Date: Fri, 12 May 2023 23:03:50 +0900 Subject: [PATCH 3/3] =?UTF-8?q?=E2=9A=A1=EF=B8=8F=20::=20=EB=B0=80?= =?UTF-8?q?=EB=A6=AC=EC=84=B8=EC=BB=A8=EB=93=9C=EB=A5=BC=20=EC=82=AC?= =?UTF-8?q?=EC=9A=A9=ED=95=98=EB=8A=94=20ToDate=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Data/Local/DataSource/LoaclTokenDataSourceImpl.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Services/AuthService/Sources/Data/Local/DataSource/LoaclTokenDataSourceImpl.swift b/Services/AuthService/Sources/Data/Local/DataSource/LoaclTokenDataSourceImpl.swift index 80d30428..d50a349d 100644 --- a/Services/AuthService/Sources/Data/Local/DataSource/LoaclTokenDataSourceImpl.swift +++ b/Services/AuthService/Sources/Data/Local/DataSource/LoaclTokenDataSourceImpl.swift @@ -32,7 +32,7 @@ class LoaclTokenDataSourceImpl: LoaclTokenDataSource { } func fetchExpiredDate() -> Date? { - self.keychain.get(.expiredAt)?.toDate(format: .fullDateWithTime) + self.keychain.get(.expiredAt)?.toDate(format: .fullDateWithMilliSecondTime) } func resetToken() {