Skip to content

Commit

Permalink
Prevent remote-change events in RealtimeSyncOff mode
Browse files Browse the repository at this point in the history
  • Loading branch information
humdrum committed May 28, 2024
1 parent d32e035 commit ad7c5c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/Core/Client.swift
Original file line number Diff line number Diff line change
Expand Up @@ -715,7 +715,7 @@ public actor Client {

// NOTE(chacha912, hackerwins): If syncLoop already executed with
// PushPull, ignore the response when the syncMode is PushOnly.
if responsePack.hasChanges(), attachment.syncMode == .realtimePushOnly {
if responsePack.hasChanges(), (attachment.syncMode == .realtimePushOnly || attachment.syncMode == .realtimeSyncOff) {
return doc
}

Expand Down

0 comments on commit ad7c5c5

Please sign in to comment.