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

Prevent duplicate Game PRs #2907

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Prevent duplicate Game PRs #2907

wants to merge 2 commits into from

Conversation

DevIos01
Copy link
Member

This update fixes #2835 and ensures that the "Publish The Game" button is disabled while publishing is in progress, preventing users from accidentally creating multiple PRs by clicking it multiple times.

This update fixes #2835 and ensures that the "Publish The Game" button is disabled while publishing is in progress, preventing users from accidentally creating multiple PRs by clicking it multiple times.
@DevIos01 DevIos01 self-assigned this Feb 19, 2025
Copy link

vercel bot commented Feb 19, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sprig ❌ Failed (Inspect) Feb 19, 2025 3:25pm

Copy link
Contributor

@grymmy grymmy left a comment

Choose a reason for hiding this comment

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

Does this handle the scenario where a user closes their Sprig browser window and then comes back a day later to work on their game, and then presses publish a 2nd time?

@DevIos01
Copy link
Member Author

Does this handle the scenario where a user closes their Sprig browser window and then comes back a day later to work on their game, and then presses publish a 2nd time?

The issue for this case aka #2835 from my testing has been that it only create duplicate if you double / multiple press the "Publish the Game" this prevents / locks out the button after first click and also double check if the button was press earlier then it get ignored , testing it worked fine and created only one pr

regarding your scenario, i am bit confused on which state you meant but

if a user publish a game then close the browser, and come back later and try to click "Publish to Github" as the game is aleardy published / PR created , it will show the "successfully publish" UI and not the "Create your project again"
Screenshot 2025-02-19 at 19 19 31

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.

Double PR
2 participants