Open davejesch opened 5 years ago
In researching this, it seems that any Pull request will fail. The error is incorrectly being displayed as "Failed to Sync. Please save Changes first."
Also, noticed that Push operations are not behaving correctly: the code is not finding and updating an existing menu, rather it deletes the menu and creates it all over again.
The plugin is using postmeta data to store source/target ids. It should be using the SyncModel for this purpose.
Parent IDs are not correctly being matched up so child menu items are being sync'd as a flat menu in some cases.
A complete rewrite of the code will be needed to address these issues.
Updated the code. Not ready for testing just yet as this requires an update to WPSS core which has not yet be checked in.
STEPS TO REPRODUCE:
RESULT:
Get the message "Failed to Sync Menu. Please Save Changes First." but no changes were made to the menu on the Source site so no need to save the changes before performing the Pull.
EXPECTED RESULT:
Successful Pull of menu from Target site.