Skip to content

Commit

Permalink
Refactor SquashedLocalChanges to LocalChanges
Browse files Browse the repository at this point in the history
  • Loading branch information
ndegwamartin committed Sep 14, 2023
1 parent 49ca6fa commit 95633d2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion engine/src/main/java/com/google/android/fhir/FhirEngine.kt
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ interface FhirEngine {
* an empty list.
*/
suspend fun getLocalChanges(type: ResourceType, id: String): List<LocalChange>
suspend fun getUnsyncedLocalChanges(): List<SquashedLocalChange>
suspend fun getUnsyncedLocalChanges(): List<LocalChange>
/**
* Purges a resource from the database based on resource type and id without any deletion of data
* from the server.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,7 @@ internal class FhirEngineImpl(private val database: Database, private val contex
return database.getLocalChanges(type, id)
}
// FhirEngineImpl.kt
override suspend fun getUnsyncedLocalChanges(): List<SquashedLocalChange> =
database.getAllLocalChanges()
override suspend fun getUnsyncedLocalChanges(): List<LocalChange> = database.getAllLocalChanges()

override suspend fun purge(type: ResourceType, id: String, forcePurge: Boolean) {
database.purge(type, id, forcePurge)
Expand Down

0 comments on commit 95633d2

Please sign in to comment.