• Resolved grayzee

    (@grayzee)


    Im using wp_insert_post to create a post on a form submission… How ever i cant update ACF fields when using this so after the post is created I use

    update_field(‘contact_us_first_name’, $get_first_name, $postId);

    to update the ACF fields within the post created. How ever it appears ObjectSync is triggering on the post creation so the update_field command has not been run and the post is being synced with missing fields.

    Is it possible to delay the post sync so that the post has time for the update_field command to run and populate the post with all the correct data needed?

Viewing 1 replies (of 1 total)
  • Plugin Author Jonathan Stegall

    (@jonathanstegall)

    I’m not aware of any way to do this. It’s been a limitation in how this plugin works because it’s a limitation of how WordPress works. In WordPress core events (create, update, delete) of core objects, the metadata is handled in separate events and there aren’t any existing ways to hook into WordPress that can retrieve all the data together.

    There might be ways to do this, but you’d have to work around the ways that WordPress works instead of working with it.

Viewing 1 replies (of 1 total)

The topic ‘Delay sync from wordpress to salesfroce’ is closed to new replies.