Skip to content

Commit cbf0055

Browse files
committed
removed testing condition
1 parent 14d25a8 commit cbf0055

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

components/ContactForm.js

+2
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ export default function ContactForm() {
3333

3434
// A contact form with a name, email, and message using tailwind css.
3535
// TODO: Add a better validation both UI, logic, and backend.
36+
// TODO: Add a display of errors if they occur.
3637
return (
3738
<div id="contact" className="min-h-screen grid place-items-center content-center p-4">
3839
<div className="max-w-8xl w-full flex flex-wrap justify-center">
@@ -55,6 +56,7 @@ export default function ContactForm() {
5556
</label>
5657
<textarea required className="appearance-none block w-full bg-gray-200 h-40 text-gray-700 border border-gray-200 rounded py-3 px-4 mb-3 leading-tight focus:outline-none focus:bg-white focus:border-gray-500" id="grid-message" type="text" placeholder="Lets get coffee." ref={messageRef} />
5758
{success && <Alert type="success">Message sent!</Alert>}
59+
5860
</div>
5961
</div>
6062
<div className="flex items-center justify-center">

pages/api/contact.js

-4
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,6 @@ import sendgrid from '@sendgrid/mail';
33
sendgrid.setApiKey(process.env.SENDGRID_API_KEY);
44

55
export default async function handler(req, res) {
6-
return res.status(200).json({
7-
statusCode: 200,
8-
body: 'Hello, world!',
9-
});
106
if (req.method === 'POST') {
117
const { name, email, message } = req.body;
128

0 commit comments

Comments
 (0)