-
Notifications
You must be signed in to change notification settings - Fork 156
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
Internal distribution should prepare posts the same for push or pull #169
Internal distribution should prepare posts the same for push or pull #169
Conversation
I will fix whatever is causing the build to fail and push it again. |
e40a3fa
to
ad7f3c1
Compare
ad7f3c1
to
bd8e8a9
Compare
Build is passing now. Unit tests needed to return an ID property from the get_post mock to avoid warnings. |
Thank @rmarscher! Could you please fix the conflict in |
Please hold the merging, I'm waiting for the 570 to be merged to have final testing. |
@dinhtungdu #570 has been merged now, so this is ready for testing again. |
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.
Both push and pull worked in my test. No error or warning. Tests are passed here: https://travis-ci.org/github/dinhtungdu/distributor/builds/674211646
Thanks for working on merging this. Sorry I was unable to look at it when requested. 🏆 |
Switches the internal connection push method to prepare WP_Post objects in the same way as done by the pull method. This enables the post meta to be filtered when pushing which allows for a workaround to #168 .
I added a
@since
tag to the new\Distributor\Utils\prepare_post()
function that will probably need to be edited. This may need to be part of a minor version bump instead of a patch bump since it slightly affects people already using the dt_push_post_args filter - but it seems pretty unlikely that it would cause an issue.