-
-
Notifications
You must be signed in to change notification settings - Fork 6
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: Prevent incomplete submissions and defer captcha verification #92
Conversation
✅ Deploy Preview for qtmmirror ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
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.
These changes enable the add button only when users hover over the add button. As hovering is only possible on desktop, these changes would block mobile users from being able to submit moments.
Instead, the core functionality should be tied to clicking which is possible on all devices.
I suggest:
|
Oh yeah! I completly forgot about mobile. Great catch! Will process the changes you suggest! 👍 |
@jokroese I have updated the PR from your comments. Super nice and swifty the |
b3e8115
to
3ec6e92
Compare
I see #76 just got resolve? Else we could also add this to src/routes/moments/+server.ts on line 12
|
With the latest changes that disable/enable the AddButton reactively we can be confident that empty descriptions cannot reach the server. Only when the description is present (plus the point coordinates) can the moment be submitted. I would assume the PR as it is now should be fine and #76 can be considered fixed but if the general consensus is to add the server guard i’m happy to add it too. |
@jokroese @Elie-Simard I thought thoroughly about @Elie-Simard comment regarding #76 and it is not overkill to also add the check at the server level. This however made me realize that the real solution is to improve the data model at DB level and add a migration to that makes descritpions or coordinates |
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.
Simple, elegant, beautiful.
Related Issues
Fixes #91 and adds input verification before allowing for moment submission
Proposed Changes (Optional)
Additional context (Optional)