🐛 Fix issue sending tags when creating a conversation (HelpScout) (#1501)

This commit is contained in:
Ricardo Espinoza
2021-03-01 17:38:22 -05:00
committed by GitHub
parent 3ff7d3af39
commit f13a2781a6
5 changed files with 31 additions and 19 deletions

View File

@@ -15,13 +15,15 @@ import {
helpscoutApiRequestAllItems,
} from './GenericFunctions';
import { createHmac } from 'crypto';
import {
createHmac,
} from 'crypto';
export class HelpScoutTrigger implements INodeType {
description: INodeTypeDescription = {
displayName: 'HelpScout Trigger',
name: 'helpScoutTrigger',
icon: 'file:helpScout.png',
icon: 'file:helpScout.svg',
group: ['trigger'],
version: 1,
description: 'Starts the workflow when HelpScout events occure.',
@@ -125,7 +127,7 @@ export class HelpScoutTrigger implements INodeType {
if (webhook.url === webhookUrl) {
for (const event of events) {
if (!webhook.events.includes(event)
&& webhook.state === 'enabled') {
&& webhook.state === 'enabled') {
return false;
}
}
@@ -186,7 +188,7 @@ export class HelpScoutTrigger implements INodeType {
const bodyData = this.getBodyData();
const headerData = this.getHeaderData() as IDataObject;
const webhookData = this.getWorkflowStaticData('node');
if (headerData['x-helpscout-signature'] === undefined) {
if (headerData['x-helpscout-signature'] === undefined) {
return {};
}
//@ts-ignore