You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(DataStore): created and deleted model on one device appears as created on the other (#3554)
* fix(DataStore): created and deleted model on one device appears as created on the other (#3553)
* fix(DataStore): created and deleted model on one device appears as created on the other #3553
Co-authored-by: Di Wu <github@wudi.me>
* fix(DataStore): created and deleted model on one device appears as created on the other #3553
---------
Co-authored-by: Di Wu <github@wudi.me>
Copy file name to clipboardExpand all lines: AmplifyPlugins/DataStore/Sources/AWSDataStorePlugin/Sync/SubscriptionSync/ReconcileAndLocalSave/RemoteSyncReconciler.swift
+25-10Lines changed: 25 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -33,26 +33,41 @@ struct RemoteSyncReconciler {
33
33
}
34
34
}
35
35
36
-
37
36
/// Reconciles the incoming `remoteModels` against the local metadata to get the disposition
38
37
///
38
+
/// GroupBy the remoteModels by model identifier and apply only the latest version of the remoteModel
39
+
///
39
40
/// - Parameters:
40
41
/// - remoteModels: models retrieved from the remote store
41
42
/// - localMetadatas: metadata retrieved from the local store
42
43
/// - Returns: disposition of models to apply locally
Copy file name to clipboardExpand all lines: AmplifyPlugins/DataStore/Tests/AWSDataStorePluginTests/Sync/SubscriptionSync/RemoteSyncReconcilerTests.swift
+27Lines changed: 27 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -179,6 +179,33 @@ class RemoteSyncReconcilerTests: XCTestCase {
0 commit comments