How can I push the last changes of a document from a user after changing the channel

Hello,

My requirements:
Each document belongs to a category and these categories are considered as a channel.

Example.
DocA -> channelA -> UserA, UserB (DocA belongs to ChannelA and ChannelA is used by UserA and UserB).
UserA and UserB work on the same channel and everything is fine. Consider a state where UserA has unsaved changes(not synced yet to a server) and now I removed the channel access to UserA. At this state, the last changes made by the UserA is not saved in the server since the channel access is revoked. This is what happens now. So the data consolidated by the UserA is now useless. Even if I give the channelA access to UserA, it will overwrite the document details(since their revision in the server is 1 more than the UserA- This is my understanding).

My Question.
Is there any way, so that I can push the changes made by the UserA and not pull the document in the future. Or is there any workaround.

Why do you prematurely remove channel access to UserA ? Logically it would seem that that the user should continue to have access to the channel as long as you expect the changes from UserA to be synced

Write access and read access are two different things in the sync function. Unless you explicitly reject something inside of the sync function, any user is able to write regardless of channel access. Channel access is for enforcing read access only, so even if you remove a user from a channel they can continue to write to the document (though be warned that they will not receive any updates and if another user has updated it then the conflict will be non-resolvable since they don’t have permission to pull the latest changes and resolve it).