Skip to content

Commit

Permalink
🐛 (webhook) Fix legacy webhook {{state}} body parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
baptisteArno committed Nov 12, 2023
1 parent bac2393 commit 63233eb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ const getBodyContent =
variables: Variable[]
isCustomBody?: boolean
}): Promise<string | undefined> => {
return isEmpty(body) && isCustomBody !== true
return body === '{{state}}' || isEmpty(body) || isCustomBody !== true
? JSON.stringify(
resultValues
? parseAnswers({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ const getBodyContent = async ({
variables: Variable[]
isCustomBody?: boolean
}): Promise<string | undefined> => {
return isEmpty(body) && isCustomBody !== true
return body === '{{state}}' || isEmpty(body) || isCustomBody !== true
? JSON.stringify(
parseAnswers({
answers,
Expand Down

3 comments on commit 63233eb

@vercel
Copy link

@vercel vercel bot commented on 63233eb Nov 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vercel
Copy link

@vercel vercel bot commented on 63233eb Nov 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

builder-v2 – ./apps/builder

builder-v2-git-main-typebot-io.vercel.app
builder-v2-typebot-io.vercel.app
app.typebot.io

@vercel
Copy link

@vercel vercel bot commented on 63233eb Nov 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.