🐛 Fix another issue with Postmark Trigger node

This commit is contained in:
Jan Oberhauser 2020-09-14 13:05:21 +02:00
parent acd50ab8cd
commit c123d44e17

View file

@ -124,12 +124,18 @@ export class PostmarkTrigger implements INodeType {
const webhookData = this.getWorkflowStaticData('node');
const webhookUrl = this.getNodeWebhookUrl('default');
const events = this.getNodeParameter('events') as string[];
if (events.includes('bounce') || events.includes('spamComplaint')) {
if (this.getNodeParameter('includeContent') as boolean) {
events.push('includeContent');
}
if (events.includes('open') && this.getNodeParameter('firstOpen') as boolean) {
}
if (events.includes('open')) {
if (this.getNodeParameter('firstOpen') as boolean) {
events.push('firstOpen');
}
}
// Get all webhooks
const endpoint = `/webhooks`;