Add standalone audience response HTML page#71
Add standalone audience response HTML page#71stevetodman wants to merge 1 commit intoclaude/add-dependabot-011CUuuS9RfZqAhUaWSZCqADfrom
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const submitResponse = () => { | ||
| if (selectedAnswer) { | ||
| db.submitResponse(sessionId, { answer: selectedAnswer }); | ||
| setHasSubmitted(true); |
There was a problem hiding this comment.
Only mark submission successful after Firebase write succeeds
In the student view, the submit handler sets hasSubmitted to true immediately after invoking db.submitResponse without awaiting or checking the returned promise. If the network request fails or the Firebase write is rejected, the UI still shows “Response Submitted” and disables further interaction, so the vote is silently dropped and cannot be retried. Consider awaiting the promise and only transitioning to the success state on fulfillment (showing an error and leaving hasSubmitted false on rejection) to keep the response counts accurate.
Useful? React with 👍 / 👎.
Summary
Testing
Codex Task