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: adjust timing of storage retrieval due to race conditions #90

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

JacobCoffee
Copy link
Member

@JacobCoffee JacobCoffee commented Mar 13, 2025

The storage.get returns a promise but we don't await the result and just immediately returned the favorites of that user so it would take some refreshes for things to take effect... or something.

Move the things inside of the then's so it waits for the data

@JacobCoffee JacobCoffee requested a review from ewdurbin March 13, 2025 20:52
@ewdurbin
Copy link
Member

This is working much smoother overall, but I notice that the "swipe" to favorite/unfavorite is still a little sketchy.

I dunno if it is used, but it is reproducible in a browser by click-hold-sliding left.

Copy link
Member

@ewdurbin ewdurbin left a comment

Choose a reason for hiding this comment

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

Extremely not blocking, but this makes me think: What if we add a "key_prefix" variable in the configuration that we applied to all the keys we have in storage to make this a one-time change each year that negates all state from previous years 💭

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants