-
Notifications
You must be signed in to change notification settings - Fork 368
-
Notifications
You must be signed in to change notification settings - Fork 368
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
getTags returns only tags first time #97
Comments
@jzeferino Thanks for the report. Are you calling From a quick review of the SDK code it seems there could be an issue where calling |
@jkasten2 your welcome. Yes I'm calling |
@jzeferino I haven't been able to reproduce an issue where the first call to Line 1066 in d978cce
Could you list the steps to reproduce the issue in detail? |
Maybe my first post wasn't clear.
To reproduce this you should call the |
@jzeferino Sorry I misread that, I have fixed the issue in commit c4012fe. There is now additional tests around this method call to prevent any recurrence of an issue like this. |
@jkasten2 thank you |
After calling
getTags
for the first time it always returns null.The problem is in this lines:
https://github.com/OneSignal/OneSignal-Android-SDK/blob/master/OneSignalSDK/onesignal/src/main/java/com/onesignal/OneSignal.java#L777
if (tags.serverSuccess) getTagsCall = true;
and after settings this flag to true it never goes to false and in the next calls it will never call the getTags:
https://github.com/OneSignal/OneSignal-Android-SDK/blob/master/OneSignalSDK/onesignal/src/main/java/com/onesignal/OneSignal.java#L776
final OneSignalStateSynchronizer.GetTagsResult tags = OneSignalStateSynchronizer.getTags(!getTagsCall);
https://github.com/OneSignal/OneSignal-Android-SDK/blob/master/OneSignalSDK/onesignal/src/main/java/com/onesignal/OneSignalStateSynchronizer.java#L698
The text was updated successfully, but these errors were encountered: