The quickstart guide for the Optimizely Android SDK includes the following example:
private void userClickedImportantButton() {
Optimizely.trackEvent("ImportantButtonClicked");
Optimizely.dispatchEvents(); // Manually send the event logs back to the server
}
This can be found here
However, the example is incorrect and doesn't actually work - it appears that dispatchEvents()
is an instance method, not static method, of the Optimizely
class.
What is the correct way to use it?