mirror of
https://github.com/System-End/site.git
synced 2026-04-19 22:05:11 +00:00
Re-add api route
wooooooo
This commit is contained in:
parent
03b216e3fa
commit
6a4b40812b
2 changed files with 1 additions and 4 deletions
|
|
@ -50,7 +50,7 @@ const JoinForm = () => {
|
|||
body: JSON.stringify({ name, email, teen, reason })
|
||||
})
|
||||
.then((r) => r.json())
|
||||
.then((r) => { console.log(r); setStatus(r.status) })
|
||||
.then((r) => setStatus(r.status))
|
||||
.catch((e) => console.error(e))
|
||||
}}
|
||||
>
|
||||
|
|
|
|||
|
|
@ -8,10 +8,7 @@ const joinTable = new AirtablePlus({
|
|||
|
||||
export default async (req, res) => {
|
||||
if (req.method === 'POST') {
|
||||
console.log('hi')
|
||||
const data = JSON.parse(req.body)
|
||||
console.log(data)
|
||||
console.log(data.name)
|
||||
await joinTable.create({
|
||||
'Full Name': data.name,
|
||||
'Email Address': data.email,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue