Repository navigation
fix: restore EmailJS recipient params as a stopgap - #5
Merged
Merged
Conversation
Live-verified after merging #4: the template's "To email" field is still {{to_email}}, so removing these params made every send 422 with "the recipients address is empty" (reproduced directly against the EmailJS API). This restores the previous routing-to-sender behavior so the form works again immediately. Real fix is a one-time EmailJS dashboard change (hard-code "To email" to Dom's address on template_51fi6xw) per docs/plans/01-reconnect-live-plumbing.md step 3 — once that's done, revert this commit.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Live-verified regression from #4: the contact form 422s for every visitor right now with "The recipients address is empty" — reproduced directly against
https://api.emailjs.com/api/v1.0/email/sendusing the credentials shipped in the live bundle.Root cause:
template_51fi6xw's "To email" field is still{{to_email}}. #4 removed theto_email/to_nameparams (they were misleading — routing to the visitor rather than Dom), but nothing else fills that template variable, so EmailJS rejects the send with an empty recipient.Fix
Restores
to_name/to_emailinlib/services/emailjs.tsas a stopgap — routes to the sender again (the original pre-#4 behavior), not to Dom, until the EmailJS dashboard template is hard-coded to his address perdocs/plans/01-reconnect-live-plumbing.mdstep 3. Once that dashboard change is made, this commit should be reverted.Verified against the live EmailJS API: the same request that 422'd without these params returns
200 OKwith them restored (tested againstexample.com, a reserved non-routable domain — nothing was actually delivered).Test plan
npx tsc --noEmit,npm run lint(2 pre-existing, unrelated errors — unchanged)npm test -- --run— 27/27 passnpm run buildsucceeds🤖 Generated with Claude Code