Skip to content

Commit 1ad63fe

Browse files
committed
Remove old copy method entirely
1 parent 50df648 commit 1ad63fe

File tree

1 file changed

+0
-32
lines changed

1 file changed

+0
-32
lines changed

Diff for: core/src/commonMain/kotlin/com/powersync/sync/SyncStatus.kt

-32
Original file line numberDiff line numberDiff line change
@@ -154,38 +154,6 @@ public data class SyncStatus internal constructor(
154154
*/
155155
public fun asFlow(): SharedFlow<SyncStatusData> = stateFlow.asSharedFlow()
156156

157-
/**
158-
* Updates the internal sync status indicators and emits Flow updates
159-
*/
160-
@Deprecated("Use callback-based approach instead")
161-
internal fun update(
162-
connected: Boolean? = null,
163-
connecting: Boolean? = null,
164-
downloading: Boolean? = null,
165-
uploading: Boolean? = null,
166-
hasSynced: Boolean? = null,
167-
lastSyncedAt: Instant? = null,
168-
uploadError: Any? = null,
169-
downloadError: Any? = null,
170-
clearUploadError: Boolean = false,
171-
clearDownloadError: Boolean = false,
172-
priorityStatusEntries: List<PriorityStatusEntry>? = null,
173-
) {
174-
data =
175-
data.copy(
176-
connected = connected ?: data.connected,
177-
connecting = connecting ?: data.connecting,
178-
downloading = downloading ?: data.downloading,
179-
uploading = uploading ?: data.uploading,
180-
lastSyncedAt = lastSyncedAt ?: data.lastSyncedAt,
181-
hasSynced = hasSynced ?: data.hasSynced,
182-
priorityStatusEntries = priorityStatusEntries ?: data.priorityStatusEntries,
183-
uploadError = if (clearUploadError) null else uploadError,
184-
downloadError = if (clearDownloadError) null else downloadError,
185-
)
186-
stateFlow.value = data
187-
}
188-
189157
/**
190158
* Updates the internal sync status indicators and emits Flow updates
191159
*/

0 commit comments

Comments
 (0)