-
Notifications
You must be signed in to change notification settings - Fork 99
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
resolveConflict()
api
#3073
resolveConflict()
api
#3073
Conversation
|
@@ -65,6 +65,7 @@ export async function newLixFile(): Promise<Blob> { | |||
conflicting_change_id TEXT NOT NULL, | |||
reason TEXT, | |||
meta TEXT, | |||
resolved_with_change_id TEXT, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Used as marker if a conflict has been resolved.
@janfjohannes if you approve the PR, merge it to unblock @NiklasBuchfink and @NilsJacobsen while I am asleep |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@samuelstroschein approved so you can proceed as you want, but i have a few comments that would probably be better improved if there is time...
Using lodash intead of `fast-deep-equal` because fast deep equal crashed.
Context
This PR introduces the possibility for apps to resolve conflicts. Closes opral/lix-sdk#49
A conflict is resolved by providing a change, which does not necessarily create a new change. If the change does not exist in the database (a resolution via merging two changes that result in a new change, for example), the function inserts the change.