Home › Forums › Calendar Products › Event Aggregator › Resynch event button fires tribe_events_facebook_event_created
- This topic has 4 replies, 2 voices, and was last updated 10 years, 1 month ago by
George.
-
AuthorPosts
-
March 7, 2016 at 10:33 am #1085934
Keith
ParticipantI’ve noticed that the resynch event button fires tribe_events_facebook_event_created. I don’t know if this happens in all cases, or only when the event date has been updated. Is there any simple way to determine whether the event has been fired as a result of clicking the resynch button?
March 7, 2016 at 11:01 am #1085940Keith
ParticipantJust to add that the event is fired every time the button is clicked, even if the event on Facebook is identical to the event in the calendar and no changes are made.
March 7, 2016 at 4:31 pm #1086073George
ParticipantHey Keith,
Thanks for reaching out!
The tribe_events_facebook_event_created action indeed does fire upon clicking the resync button—I will address your specific questions as follows:
I don’t know if this happens in all cases, or only when the event date has been updated.
The firing of that action happens in all cases. This is because the action itself is inside the create_local_event() function, which fires when an event is created OR updated—the action is at the end of the function and fires regardless of whether specific fields are even altered or not.
Is there any simple way to determine whether the event has been fired as a result of clicking the resynch button?
At this time, there is not. 🙁 Can you elaborate a bit more on your goals here? I might be able to offer some specific advice on how to add some context to the firing of that action.
Thank you!
GeorgeMarch 8, 2016 at 3:33 am #1086186Keith
ParticipantHi George,
Thanks for the response. It seems counter-intuitive that an event called tribe_events_facebook_event_created fires when events are not created, and when the database has not been altered in any way. I haven’t been able to find any documentation on the event.
The context is that I add categories and custom data to Facebook events as they are created, based on the organizerID. I don’t want that data to be duplicated when the resynch button is clicked. I’ve coded around the difficulty now so this thread can be closed.
Regards,
KeithMarch 8, 2016 at 7:37 am #1086231George
ParticipantThanks for this feedback Keith—using terminology like “updated” or “maybe_updated” instead of “created” might indeed make this section of our code a bit more clear and readable, especially outside of its normal contexts.
Best of luck with your project,
George -
AuthorPosts
- The topic ‘Resynch event button fires tribe_events_facebook_event_created’ is closed to new replies.
