Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
[5.8] fix many to many sync results with custom pivot model #28416
This PR fixes an issue (#28150) where the results of
The reason was that we weren't loading the actual pivot model from the database and thus we didn't have any way to compare the newly provided data with the existing one.
My solution here is that we load the model from the database first, and use
Hey @themsaid, I think this PR caused a breaking change for me when trying to use updateExistingPivot when there were no records found:
My code snippet:
Did I use it wrong or is it broken when no records are found?