Skip to content

Commit f4a14e5

Browse files
chore(datastore): Amplify Swift version bump to 1.30.7 (#4454)
* chore(datastore): Amplify Swift version bump to 1.30.7 * chore: add timezone to the FlutterTemporal struct
1 parent fb648d7 commit f4a14e5

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

packages/amplify_datastore/ios/Classes/types/temporal/FlutterTemporal.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,11 @@ import Foundation
88
// Stores an ISO 8601 String to be saved to Appsync
99
struct FlutterTemporal: TemporalSpec {
1010
let iso8601: String
11+
var timeZone: TimeZone?
1112
init(iso8601String: String) {
1213
self.iso8601 = iso8601String
1314
self.foundationDate = Date()
15+
self.timeZone = TimeZone.current
1416
}
1517

1618
var iso8601String: String {
@@ -21,9 +23,10 @@ struct FlutterTemporal: TemporalSpec {
2123
// In order to properly adhere to "TemporalSpec" these functions must be implemented
2224
// This class is solely for transmitting a ISO 8601 Date String to Appsync so these other functions are not needed
2325
var foundationDate: Date
24-
init(_ date: Date) {
26+
init(_ date: Date, timeZone: TimeZone? = TimeZone.current) {
2527
self.iso8601 = ""
2628
self.foundationDate = date
29+
self.timeZone = timeZone
2730
}
2831

2932
static func now() -> FlutterTemporal {

packages/amplify_datastore/ios/amplify_datastore.podspec

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ The DataStore module for Amplify Flutter.
1515
s.source = { :git => 'https://github.com/aws-amplify/amplify-flutter.git' }
1616
s.source_files = 'Classes/**/*'
1717
s.dependency 'Flutter'
18-
s.dependency 'Amplify', '1.30.4'
19-
s.dependency 'AmplifyPlugins/AWSAPIPlugin', '1.30.4'
20-
s.dependency 'AmplifyPlugins/AWSDataStorePlugin', '1.30.4'
18+
s.dependency 'Amplify', '1.30.7'
19+
s.dependency 'AmplifyPlugins/AWSAPIPlugin', '1.30.7'
20+
s.dependency 'AmplifyPlugins/AWSDataStorePlugin', '1.30.7'
2121
s.dependency 'Starscream', '4.0.4'
2222
s.platform = :ios, '13.0'
2323

0 commit comments

Comments
 (0)