diff options
Diffstat (limited to 'patches')
-rw-r--r-- | patches/expo-updates+0.24.7.patch | 26 | ||||
-rw-r--r-- | patches/expo-updates+0.24.7.patch.md | 7 |
2 files changed, 33 insertions, 0 deletions
diff --git a/patches/expo-updates+0.24.7.patch b/patches/expo-updates+0.24.7.patch new file mode 100644 index 000000000..603ae32ef --- /dev/null +++ b/patches/expo-updates+0.24.7.patch @@ -0,0 +1,26 @@ +diff --git a/node_modules/expo-updates/ios/EXUpdates/Update/NewUpdate.swift b/node_modules/expo-updates/ios/EXUpdates/Update/NewUpdate.swift +index 189a5f5..8d5b8e6 100644 +--- a/node_modules/expo-updates/ios/EXUpdates/Update/NewUpdate.swift ++++ b/node_modules/expo-updates/ios/EXUpdates/Update/NewUpdate.swift +@@ -68,13 +68,20 @@ public final class NewUpdate: Update { + processedAssets.append(asset) + } + ++ // Instead of relying on various hacks to get the correct format for the specific ++ // platform on the backend, we can just add this little patch.. ++ let dateFormatter = DateFormatter() ++ dateFormatter.locale = Locale(identifier: "en_US_POSIX") ++ dateFormatter.dateFormat = "yyyy-MM-dd'T'HH:mm:ssZ" ++ let date = dateFormatter.date(from:commitTime) ?? RCTConvert.nsDate(commitTime)! ++ + return Update( + manifest: manifest, + config: config, + database: database, + updateId: uuid, + scopeKey: config.scopeKey, +- commitTime: RCTConvert.nsDate(commitTime), ++ commitTime: date, + runtimeVersion: runtimeVersion, + keep: true, + status: UpdateStatus.StatusPending, diff --git a/patches/expo-updates+0.24.7.patch.md b/patches/expo-updates+0.24.7.patch.md new file mode 100644 index 000000000..8a8848127 --- /dev/null +++ b/patches/expo-updates+0.24.7.patch.md @@ -0,0 +1,7 @@ +# Expo-Updates Patch + +This is a small patch to convert timestamp formats that are returned from the backend. Instead of relying on the +backend to return the correct format for a specific format (the format required on Android is not the same as on iOS) +we can just add this conversion in. + +Don't remove unless we make changes on the backend to support both platforms. \ No newline at end of file |