Skip to content
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

Fix incorrect condition for determining if all tracking data was deleted #179

Merged

Conversation

Kevinsomnia
Copy link
Contributor

Fixes a bug introduced in #152, where the ID is never reset. Instead of checking dataIndex == maxIndex, it should be dataIndex > maxIndex, since the last iteration of the while loop increments dataIndex past maxIndex before stopping. In other words, the dataIndex is no longer in bounds at this point.

Also I revised the comment for brevity.

@zihejia zihejia added the bug label Sep 24, 2024
@zihejia
Copy link
Contributor

zihejia commented Sep 24, 2024

Thanks @Kevinsomnia !

Copy link
Contributor

@zihejia zihejia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@zihejia zihejia merged commit fa38d02 into mixpanel:master Sep 24, 2024
@Kevinsomnia Kevinsomnia deleted the fix/player-prefs-optimization-bug branch September 25, 2024 02:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants