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

Replaced campaignPreference with CAMPAIGNS_DEFAULT_PREFERENCE #5357

Conversation

Kwong-Yu-Zhou
Copy link
Contributor

Fixed the bug "Swiping campaign notification shows 'You won't see campaigns anymore', but actually same notification comes back after a few days."

Fixes #5288

What changes did you make and why?

I replaced the variable campaignPreference with CAMPAIGNS_DEFAULT_PREFERENCE.

In the ContributionsFragment class, the function fetchCampaigns() checks the CAMPAIGNS_DEFAULT_PREFERENCE if it is True. However, in the CampaignView class, it switches campaignPreference to False without updating the default preference after swiping.

} else if (store.getBoolean(CampaignView.CAMPAIGNS_DEFAULT_PREFERENCE, true)) {

Tested {} on {emulator 32.1.12-9751036} with API level {API Tiramisu}.

Screenshots (for UI changes only)

Need help? See https://support.google.com/android/answer/9075928


Note: Please ensure that you have read CONTRIBUTING.md if this is your first pull request.

@nicolas-raoul
Copy link
Member

I added a currently-running campaign so that it can be tested.
Strangely now I can nor reproduce the issue on the main branch... are you able to reproduce it? if yes, any tip to make it happen reliably? Thanks! :-)

@domdomegg domdomegg merged commit 013bc7d into commons-app:main Feb 14, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants