2
0

fix(viewer): 🐛 Better result initialization

This commit is contained in:
Baptiste Arnaud
2022-03-25 11:16:46 +01:00
parent 2ae326c102
commit de784820eb
4 changed files with 23 additions and 36 deletions

View File

@ -1,15 +1,10 @@
import { Log, Result } from 'db'
import { VariableWithValue } from 'models'
import { sendRequest } from 'utils'
export const createResult = async (
typebotId: string,
prefilledVariables: VariableWithValue[]
) => {
export const createResult = async (typebotId: string) => {
return sendRequest<Result>({
url: `/api/typebots/${typebotId}/results`,
method: 'POST',
body: { prefilledVariables },
})
}