Skip to content

Commit 2c2332f

Browse files
committed
Fix sync progress regression
1 parent 8830a8f commit 2c2332f

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

core/src/commonIntegrationTest/kotlin/com/powersync/sync/SyncIntegrationTest.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import io.kotest.matchers.shouldBe
2828
import kotlinx.coroutines.CompletableDeferred
2929
import kotlinx.coroutines.DelicateCoroutinesApi
3030
import kotlinx.coroutines.launch
31+
import kotlinx.serialization.encodeToString
3132
import kotlin.test.Test
3233
import kotlin.test.assertEquals
3334
import kotlin.test.assertFailsWith

core/src/commonMain/kotlin/com/powersync/sync/Progress.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ public data class SyncDownloadProgress internal constructor(
143143
put(
144144
bucket.bucket,
145145
previous.copy(
146-
sinceLast = min(previous.sinceLast + bucket.data.size, previous.total),
146+
sinceLast = min(previous.sinceLast + bucket.data.size, previous.targetCount),
147147
),
148148
)
149149
}

0 commit comments

Comments
 (0)