Skip to content

Commit ce1d283

Browse files
fix(Recaptcha): $fetch.raw
1 parent 2f20243 commit ce1d283

File tree

1 file changed

+10
-22
lines changed

1 file changed

+10
-22
lines changed

components/Recaptcha.vue

Lines changed: 10 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -81,28 +81,16 @@
8181
}
8282
})
8383
async function submit_recaptcha() {
84-
const response = await $fetch(
85-
`/.netlify/functions/recaptcha`,
86-
{
87-
method: "POST",
88-
body: {
89-
name: name.value,
90-
email: email.value,
91-
launch: launch.value,
92-
},
84+
const response = await $fetch.raw(`/.netlify/functions/recaptcha`, {
85+
method: "POST",
86+
body: {
87+
name: name.value,
88+
email: email.value,
89+
launch: launch.value,
9390
},
94-
{
95-
onResponse({ response }) {
96-
console.log("onResponse", { response })
97-
if (response.ok) {
98-
infra_store.$patch({
99-
is_captcha_validated: response.status === 200,
100-
})
101-
}
102-
},
103-
},
104-
)
105-
106-
console.log("response", response)
91+
})
92+
infra_store.$patch({
93+
is_captcha_validated: response.status === 200,
94+
})
10795
}
10896
</script>

0 commit comments

Comments
 (0)