diff --git a/client/common/configuration/elements/channel-configuration.ts b/client/common/configuration/elements/channel-configuration.ts index 75254c4c..2e02945f 100644 --- a/client/common/configuration/elements/channel-configuration.ts +++ b/client/common/configuration/elements/channel-configuration.ts @@ -103,7 +103,7 @@ export class ChannelConfigurationElement extends LivechatElement { colName: ptTr(LOC_LIVECHAT_CONFIGURATION_CHANNEL_FORBIDDEN_WORDS_LABEL), description: ptTr(LOC_LIVECHAT_CONFIGURATION_CHANNEL_FORBIDDEN_WORDS_DESC2) }, - regex: { + regexp: { colName: ptTr(LOC_LIVECHAT_CONFIGURATION_CHANNEL_FORBIDDEN_WORDS_REGEXP_LABEL), description: ptTr(LOC_LIVECHAT_CONFIGURATION_CHANNEL_FORBIDDEN_WORDS_REGEXP_DESC) }, @@ -152,7 +152,7 @@ export class ChannelConfigurationElement extends LivechatElement { default: [], separators: ['\n', '\t', ';'] }, - regex: { + regexp: { inputType: 'checkbox', default: false }, diff --git a/client/common/configuration/services/channel-details.ts b/client/common/configuration/services/channel-details.ts index 91aaa773..75ba4b2b 100644 --- a/client/common/configuration/services/channel-details.ts +++ b/client/common/configuration/services/channel-details.ts @@ -61,8 +61,8 @@ export class ChannelDetailsService { if (fw.regexp) { if (v.trim() !== '') { try { - const test = new RegExp(v) - test.test(v) + // eslint-disable-next-line no-new + new RegExp(v) } catch (_) { validationError.properties[`bot.forbiddenWords.${i}.entries`] .push(ValidationErrorType.WrongFormat) diff --git a/client/common/lib/elements/dynamic-table-form.ts b/client/common/lib/elements/dynamic-table-form.ts index 1d4ccf17..ab724d6a 100644 --- a/client/common/lib/elements/dynamic-table-form.ts +++ b/client/common/lib/elements/dynamic-table-form.ts @@ -594,8 +594,6 @@ export class DynamicTableFormElement extends LivechatElement { : target.value : undefined - console.log(`value: ${JSON.stringify(value)}`) - if (value !== undefined) { for (const rowById of this._rowsById) { if (rowById._id === rowId) {