@@ -162,8 +162,7 @@ export const startSession = async ({
|
||||
typebot: {
|
||||
id: typebot.id,
|
||||
settings: deepParseVariables(
|
||||
initialState.typebotsQueue[0].typebot.variables,
|
||||
{ removeEmptyStrings: true }
|
||||
initialState.typebotsQueue[0].typebot.variables
|
||||
)(typebot.settings),
|
||||
theme: sanitizeAndParseTheme(typebot.theme, {
|
||||
variables: initialState.typebotsQueue[0].typebot.variables,
|
||||
@@ -274,8 +273,7 @@ export const startSession = async ({
|
||||
typebot: {
|
||||
id: typebot.id,
|
||||
settings: deepParseVariables(
|
||||
newSessionState.typebotsQueue[0].typebot.variables,
|
||||
{ removeEmptyStrings: true }
|
||||
newSessionState.typebotsQueue[0].typebot.variables
|
||||
)(typebot.settings),
|
||||
theme: sanitizeAndParseTheme(typebot.theme, {
|
||||
variables: initialState.typebotsQueue[0].typebot.variables,
|
||||
@@ -293,8 +291,7 @@ export const startSession = async ({
|
||||
typebot: {
|
||||
id: typebot.id,
|
||||
settings: deepParseVariables(
|
||||
newSessionState.typebotsQueue[0].typebot.variables,
|
||||
{ removeEmptyStrings: true }
|
||||
newSessionState.typebotsQueue[0].typebot.variables
|
||||
)(typebot.settings),
|
||||
theme: sanitizeAndParseTheme(typebot.theme, {
|
||||
variables: initialState.typebotsQueue[0].typebot.variables,
|
||||
@@ -472,11 +469,9 @@ const sanitizeAndParseTheme = (
|
||||
{ variables }: { variables: Variable[] }
|
||||
): Theme => ({
|
||||
general: theme.general
|
||||
? deepParseVariables(variables, { removeEmptyStrings: true })(theme.general)
|
||||
: undefined,
|
||||
chat: theme.chat
|
||||
? deepParseVariables(variables, { removeEmptyStrings: true })(theme.chat)
|
||||
? deepParseVariables(variables)(theme.general)
|
||||
: undefined,
|
||||
chat: theme.chat ? deepParseVariables(variables)(theme.chat) : undefined,
|
||||
customCss: theme.customCss
|
||||
? removeLiteBadgeCss(parseVariables(variables)(theme.customCss))
|
||||
: undefined,
|
||||
|
||||
Reference in New Issue
Block a user