From d7390ec44f528ec69bd34cfa1dde4a8ea167239f Mon Sep 17 00:00:00 2001 From: Timofey Solomko Date: Sun, 28 Jan 2018 19:58:40 +0300 Subject: [PATCH] [ZIP] Native time and date are now relative to current timezone and calendar used by system --- Sources/ZIP/ZipEntryInfo.swift | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Sources/ZIP/ZipEntryInfo.swift b/Sources/ZIP/ZipEntryInfo.swift index 4ecaf025..0b4adcee 100644 --- a/Sources/ZIP/ZipEntryInfo.swift +++ b/Sources/ZIP/ZipEntryInfo.swift @@ -113,8 +113,7 @@ public struct ZipEntryInfo: ContainerEntryInfo { let minutes = (dosTime & 0x7E0) >> 5 let hours = (dosTime & 0xF800) >> 11 - self.modificationTime = DateComponents(calendar: Calendar(identifier: .iso8601), - timeZone: TimeZone(abbreviation: "UTC"), + self.modificationTime = DateComponents(calendar: Calendar.current, timeZone: TimeZone.current, year: year, month: month, day: day, hour: hours, minute: minutes, second: seconds).date }