From 51f92daab5ed75855d5517dabb5ab1f45c25b383 Mon Sep 17 00:00:00 2001 From: Amy Kapernick Date: Sat, 3 Feb 2024 02:35:26 +0800 Subject: [PATCH] fixed characters --- src/app/actions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/actions.ts b/src/app/actions.ts index bb9452d..c2bd582 100644 --- a/src/app/actions.ts +++ b/src/app/actions.ts @@ -46,7 +46,7 @@ export async function submit (guest: string, formData: FormData) fieldValue = 'true' } - const fieldData = notionFields[type].replace('{{value}}', fieldValue.replace('"', '\\"')) + const fieldData = notionFields[type].replace('{{value}}', fieldValue.replace(/[.*+?^${}()|[\]\\]/g, '\\$&')) updatedData[id] = { ...updatedData[id],