fix(Google Calendar Trigger Node): Fix issue preventing birthday and holiday calendars from working (#7832)

Github issue / Community forum post (link here to close automatically):
https://community.n8n.io/t/issue-with-some-google-calendars/33411

---------

Co-authored-by: Michael Kret <michael.k@radency.com>
This commit is contained in:
Jon 2023-11-28 09:11:05 +00:00 committed by GitHub
parent d5488725a8
commit 38f24a6184
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -9,7 +9,12 @@ import { NodeApiError, NodeOperationError } from 'n8n-workflow';
import moment from 'moment';
import { getCalendars, googleApiRequest, googleApiRequestAllItems } from './GenericFunctions';
import {
encodeURIComponentOnce,
getCalendars,
googleApiRequest,
googleApiRequestAllItems,
} from './GenericFunctions';
export class GoogleCalendarTrigger implements INodeType {
description: INodeTypeDescription = {
@ -132,7 +137,9 @@ export class GoogleCalendarTrigger implements INodeType {
async poll(this: IPollFunctions): Promise<INodeExecutionData[][] | null> {
const poolTimes = this.getNodeParameter('pollTimes.item', []) as IDataObject[];
const triggerOn = this.getNodeParameter('triggerOn', '') as string;
const calendarId = this.getNodeParameter('calendarId', '', { extractValue: true }) as string;
const calendarId = encodeURIComponentOnce(
this.getNodeParameter('calendarId', '', { extractValue: true }) as string,
);
const webhookData = this.getWorkflowStaticData('node');
const matchTerm = this.getNodeParameter('options.matchTerm', '') as string;