-
-
Notifications
You must be signed in to change notification settings - Fork 35.8k
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: remove donation prevention #37867
fix: remove donation prevention #37867
Conversation
@ojeytonwilliams turns out we don't need to prevent donation since donation prompts happen less often on the previous donation modal logic. could you take a look please? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing preventDonationRequests
means that once you trigger the DonationModal
you see it every time you mount a page inside /learn
. To fix this, how about using preventDonationRequests
, but only in showDonateModalSaga
and have it flip canRequestDonation
back to false?
That way the donation message should always be visible on certs and the donation modal should only pop up after you complete a block (but if you complete multiple blocks in a session, you will see multiple modals).
@ojeytonwilliams you are right. although I am not sure I follow logic for using preventDonationRequests for setting canRequestDonation back go false. in that case what would flip canRequestDonation to true? How about flipping tryToShowDonationModal back to false after the donation pop up? |
That will happen each time you finish a block, same as before. The idea (in my last commit) is to have block completion flip |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
Update index.md
)master
branch of freeCodeCamp.Closes #XXXXX