From 44bd9e51e3183958e4a93b963920d970d28e533b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Fri, 18 Nov 2022 14:02:25 +0100 Subject: [PATCH 1/4] :blue_book: Set up overloads --- packages/workflow/src/Interfaces.ts | 37 +++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/packages/workflow/src/Interfaces.ts b/packages/workflow/src/Interfaces.ts index 9516ce8568752..32346f7e29e07 100644 --- a/packages/workflow/src/Interfaces.ts +++ b/packages/workflow/src/Interfaces.ts @@ -549,7 +549,40 @@ export interface IGetNodeParameterOptions { extractValue?: boolean; } -export interface IExecuteFunctions { +namespace ExecuteFunctions { + namespace BooleanReturning { + export type NodeParameter = + | 'binaryData' + | 'download' + | 'jsonParameters' + | 'returnAll' + | 'rawData' + | 'resolveData'; + } + + export type GetNodeParameterFn = { + // @TECH_DEBT: Refactor to remove this barely used overload - N8N-5632 + getNodeParameter( + parameterName: 'resource', + itemIndex?: number, + ): T['resource']; + + getNodeParameter( + parameterName: BooleanReturning.NodeParameter, + itemIndex: number, + fallbackValue?: any, + options?: IGetNodeParameterOptions, + ): boolean; + getNodeParameter( + parameterName: string, + itemIndex: number, + fallbackValue?: any, + options?: IGetNodeParameterOptions, + ): NodeParameterValueType | object; + }; +} + +export type IExecuteFunctions = ExecuteFunctions.GetNodeParameterFn & { continueOnFail(): boolean; evaluateExpression(expression: string, itemIndex: number): NodeParameterValueType; executeWorkflow( @@ -597,7 +630,7 @@ export interface IExecuteFunctions { ): Promise; [key: string]: (...args: any[]) => any; }; -} +}; export interface IExecuteSingleFunctions { continueOnFail(): boolean; From d8be7cc16b6c04e1b20adccf4c80e84b751aa0c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Fri, 18 Nov 2022 14:02:39 +0100 Subject: [PATCH 2/4] :blue_book: Add temporary assertion --- packages/core/src/NodeExecuteFunctions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/src/NodeExecuteFunctions.ts b/packages/core/src/NodeExecuteFunctions.ts index d56a6f7d5b56a..f93b1664d1bfd 100644 --- a/packages/core/src/NodeExecuteFunctions.ts +++ b/packages/core/src/NodeExecuteFunctions.ts @@ -2423,7 +2423,7 @@ export function getExecuteFunctions( constructExecutionMetaData, }, }; - })(workflow, runExecutionData, connectionInputData, inputData, node); + })(workflow, runExecutionData, connectionInputData, inputData, node) as IExecuteFunctions; } /** From bfc00a4c434694bff60bb06480269cc7951c012e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Fri, 18 Nov 2022 14:02:56 +0100 Subject: [PATCH 3/4] :fire: Remove inferrable boolean assertions --- .../ActiveCampaign/ActiveCampaign.node.ts | 18 ++++----- .../nodes/Affinity/Affinity.node.ts | 8 ++-- .../nodes/AgileCrm/AgileCrm.node.ts | 12 +++--- .../nodes/Airtable/Airtable.node.ts | 4 +- .../nodes/ApiTemplateIo/ApiTemplateIo.node.ts | 8 ++-- packages/nodes-base/nodes/Asana/Asana.node.ts | 6 +-- .../nodes/Automizy/Automizy.node.ts | 4 +- .../nodes/Autopilot/Autopilot.node.ts | 6 +-- .../AwsCertificateManager.node.ts | 2 +- .../nodes/Aws/DynamoDB/AwsDynamoDB.node.ts | 2 +- .../nodes-base/nodes/Aws/ELB/AwsElb.node.ts | 4 +- .../Aws/Rekognition/AwsRekognition.node.ts | 2 +- .../nodes-base/nodes/Aws/S3/AwsS3.node.ts | 10 ++--- .../nodes-base/nodes/Aws/SES/AwsSes.node.ts | 4 +- .../Aws/Transcribe/AwsTranscribe.node.ts | 2 +- .../nodes/Beeminder/Beeminder.node.ts | 2 +- .../nodes/Bitwarden/GenericFunctions.ts | 2 +- packages/nodes-base/nodes/Box/Box.node.ts | 6 +-- .../nodes/Brandfetch/Brandfetch.node.ts | 2 +- .../nodes-base/nodes/Bubble/Bubble.node.ts | 2 +- .../nodes/CircleCi/CircleCi.node.ts | 2 +- .../nodes/Cisco/Webex/CiscoWebex.node.ts | 6 +-- .../nodes-base/nodes/ClickUp/ClickUp.node.ts | 12 +++--- .../nodes/Clockify/Clockify.node.ts | 12 +++--- .../nodes/Cloudflare/Cloudflare.node.ts | 2 +- .../nodes-base/nodes/Cockpit/Cockpit.node.ts | 2 +- packages/nodes-base/nodes/Coda/Coda.node.ts | 14 +++---- .../nodes/CoinGecko/CoinGecko.node.ts | 8 ++-- .../nodes/Contentful/Contentful.node.ts | 6 +-- .../nodes/ConvertKit/ConvertKit.node.ts | 14 +++---- .../nodes/CustomerIo/CustomerIo.node.ts | 8 ++-- packages/nodes-base/nodes/Demio/Demio.node.ts | 2 +- .../nodes/Discourse/Discourse.node.ts | 8 ++-- .../nodes-base/nodes/Disqus/Disqus.node.ts | 6 +-- .../nodes-base/nodes/Dropbox/Dropbox.node.ts | 4 +- .../nodes-base/nodes/ERPNext/ERPNext.node.ts | 2 +- packages/nodes-base/nodes/Egoi/Egoi.node.ts | 6 +-- .../ElasticSecurity/GenericFunctions.ts | 2 +- packages/nodes-base/nodes/Flow/Flow.node.ts | 2 +- .../nodes/Freshdesk/Freshdesk.node.ts | 2 +- .../nodes/Freshservice/GenericFunctions.ts | 2 +- .../nodes/FreshworksCrm/GenericFunctions.ts | 2 +- .../nodes/GetResponse/GetResponse.node.ts | 2 +- packages/nodes-base/nodes/Ghost/Ghost.node.ts | 4 +- .../nodes-base/nodes/Github/Github.node.ts | 10 ++--- .../nodes-base/nodes/Gitlab/Gitlab.node.ts | 2 +- .../nodes/GoToWebinar/GenericFunctions.ts | 2 +- .../nodes/GoToWebinar/GoToWebinar.node.ts | 4 +- .../Google/Analytics/GoogleAnalytics.node.ts | 4 +- .../Google/BigQuery/GoogleBigQuery.node.ts | 2 +- .../nodes/Google/Books/GoogleBooks.node.ts | 6 +-- .../Google/Calendar/GoogleCalendar.node.ts | 2 +- .../nodes/Google/Chat/GoogleChat.node.ts | 10 ++--- .../Google/Contacts/GoogleContacts.node.ts | 6 +-- .../nodes/Google/Drive/GoogleDrive.node.ts | 4 +- .../GoogleFirebaseCloudFirestore.node.ts | 4 +- .../Google/GSuiteAdmin/GSuiteAdmin.node.ts | 4 +- .../nodes/Google/Gmail/v1/GmailV1.node.ts | 6 +-- .../nodes/Google/Gmail/v2/GmailV2.node.ts | 8 ++-- .../nodes/Google/Slides/GoogleSlides.node.ts | 4 +- .../nodes/Google/Task/GoogleTasks.node.ts | 2 +- .../nodes/Google/YouTube/YouTube.node.ts | 10 ++--- .../nodes-base/nodes/Gotify/Gotify.node.ts | 5 +-- .../nodes-base/nodes/Grafana/Grafana.node.ts | 8 ++-- packages/nodes-base/nodes/Grist/Grist.node.ts | 2 +- .../nodes/HackerNews/HackerNews.node.ts | 2 +- .../nodes-base/nodes/HaloPSA/HaloPSA.node.ts | 8 ++-- .../nodes/Harvest/GenericFunctions.ts | 2 +- .../nodes/HelpScout/HelpScout.node.ts | 12 +++--- .../nodes/HomeAssistant/HomeAssistant.node.ts | 8 ++-- .../nodes-base/nodes/Hubspot/Hubspot.node.ts | 24 ++++++------ .../nodes-base/nodes/Hunter/Hunter.node.ts | 2 +- .../nodes/Intercom/Intercom.node.ts | 14 +++---- .../nodes/InvoiceNinja/InvoiceNinja.node.ts | 12 +++--- .../nodes-base/nodes/Jenkins/Jenkins.node.ts | 2 +- packages/nodes-base/nodes/Jira/Jira.node.ts | 12 +++--- packages/nodes-base/nodes/Kafka/Kafka.node.ts | 2 +- packages/nodes-base/nodes/Keap/Keap.node.ts | 18 ++++----- .../nodes-base/nodes/Lemlist/Lemlist.node.ts | 2 +- .../nodes-base/nodes/Linear/Linear.node.ts | 2 +- .../nodes-base/nodes/Magento/Magento2.node.ts | 6 +-- .../nodes/Mailchimp/Mailchimp.node.ts | 10 ++--- .../nodes/MailerLite/MailerLite.node.ts | 2 +- .../nodes-base/nodes/Mailjet/Mailjet.node.ts | 4 +- .../nodes/Mandrill/Mandrill.node.ts | 2 +- .../nodes-base/nodes/Mautic/Mautic.node.ts | 8 ++-- .../nodes-base/nodes/Medium/Medium.node.ts | 2 +- .../Dynamics/MicrosoftDynamicsCrm.node.ts | 2 +- .../Microsoft/Excel/MicrosoftExcel.node.ts | 14 +++---- .../MicrosoftGraphSecurity.node.ts | 4 +- .../OneDrive/MicrosoftOneDrive.node.ts | 2 +- .../Outlook/MicrosoftOutlook.node.ts | 10 ++--- .../Microsoft/Teams/MicrosoftTeams.node.ts | 8 ++-- .../Microsoft/ToDo/MicrosoftToDo.node.ts | 6 +-- .../nodes-base/nodes/Mindee/Mindee.node.ts | 4 +- .../nodes-base/nodes/Misp/GenericFunctions.ts | 2 +- packages/nodes-base/nodes/Misp/Misp.node.ts | 4 +- .../nodes/MondayCom/MondayCom.node.ts | 6 +-- .../N8nTrainingCustomerDatastore.node.ts | 2 +- packages/nodes-base/nodes/Nasa/Nasa.node.ts | 4 +- .../nodes-base/nodes/Netlify/Netlify.node.ts | 4 +- .../nodes/NextCloud/NextCloud.node.ts | 2 +- .../nodes-base/nodes/NocoDB/NocoDB.node.ts | 2 +- .../nodes/Notion/v1/NotionV1.node.ts | 10 ++--- .../nodes/Notion/v2/NotionV2.node.ts | 12 +++--- packages/nodes-base/nodes/Odoo/Odoo.node.ts | 8 ++-- .../nodes/OneSimpleApi/OneSimpleApi.node.ts | 6 +-- packages/nodes-base/nodes/Orbit/Orbit.node.ts | 8 ++-- packages/nodes-base/nodes/Oura/Oura.node.ts | 2 +- .../nodes-base/nodes/Paddle/Paddle.node.ts | 18 ++++----- .../nodes/PagerDuty/PagerDuty.node.ts | 6 +-- .../nodes-base/nodes/PayPal/PayPal.node.ts | 4 +- .../nodes/Phantombuster/Phantombuster.node.ts | 8 ++-- .../nodes/PhilipsHue/PhilipsHue.node.ts | 2 +- .../nodes/Pipedrive/Pipedrive.node.ts | 26 ++++++------- .../nodes/Pushbullet/Pushbullet.node.ts | 2 +- .../nodes/QuickBase/QuickBase.node.ts | 6 +-- .../nodes/QuickBooks/QuickBooks.node.ts | 10 ++--- .../nodes/Raindrop/Raindrop.node.ts | 6 +-- .../nodes-base/nodes/Reddit/Reddit.node.ts | 6 +-- .../nodes/Rocketchat/Rocketchat.node.ts | 2 +- packages/nodes-base/nodes/S3/S3.node.ts | 8 ++-- .../nodes/Salesforce/Salesforce.node.ts | 22 +++++------ .../nodes/Salesmate/Salesmate.node.ts | 30 +++++++-------- .../nodes/SeaTable/SeaTable.node.ts | 2 +- .../SecurityScorecard.node.ts | 18 ++++----- .../nodes/SendGrid/SendGrid.node.ts | 38 +++++++++---------- .../nodes/SentryIo/SentryIo.node.ts | 12 +++--- .../nodes/ServiceNow/ServiceNow.node.ts | 24 ++++++------ .../nodes-base/nodes/Shopify/Shopify.node.ts | 4 +- packages/nodes-base/nodes/Slack/Slack.node.ts | 22 +++++------ .../nodes-base/nodes/Spotify/Spotify.node.ts | 26 ++++++------- .../nodes-base/nodes/Stackby/Stackby.node.ts | 2 +- .../nodes/Storyblok/Storyblok.node.ts | 6 +-- .../nodes-base/nodes/Strapi/Strapi.node.ts | 2 +- .../nodes-base/nodes/Strava/Strava.node.ts | 4 +- packages/nodes-base/nodes/Stripe/helpers.ts | 2 +- .../nodes/Supabase/Supabase.node.ts | 2 +- .../nodes/Taiga/GenericFunctions.ts | 2 +- .../nodes/Tapfiliate/Tapfiliate.node.ts | 4 +- .../nodes/Telegram/Telegram.node.ts | 7 ++-- .../nodes-base/nodes/TheHive/TheHive.node.ts | 22 +++++------ .../nodes/TravisCi/TravisCi.node.ts | 2 +- .../nodes-base/nodes/Trello/Trello.node.ts | 6 +-- packages/nodes-base/nodes/Twist/Twist.node.ts | 6 +-- .../nodes-base/nodes/Twitter/Twitter.node.ts | 2 +- .../UnleashedSoftware.node.ts | 4 +- .../nodes/UptimeRobot/UptimeRobot.node.ts | 8 ++-- .../VenafiTlsProtectDatacenter.node.ts | 4 +- .../VenafiTlsProtectCloud.node.ts | 4 +- packages/nodes-base/nodes/Vero/Vero.node.ts | 4 +- .../nodes-base/nodes/Webflow/Webflow.node.ts | 2 +- packages/nodes-base/nodes/Wekan/Wekan.node.ts | 8 ++-- .../nodes/WooCommerce/WooCommerce.node.ts | 6 +-- .../nodes/Wordpress/Wordpress.node.ts | 4 +- packages/nodes-base/nodes/Xero/Xero.node.ts | 4 +- .../nodes-base/nodes/Zammad/Zammad.node.ts | 8 ++-- .../nodes-base/nodes/Zendesk/Zendesk.node.ts | 14 +++---- .../nodes-base/nodes/Zoho/GenericFunctions.ts | 2 +- packages/nodes-base/nodes/Zoom/Zoom.node.ts | 6 +-- packages/nodes-base/nodes/Zulip/Zulip.node.ts | 4 +- 161 files changed, 534 insertions(+), 538 deletions(-) diff --git a/packages/nodes-base/nodes/ActiveCampaign/ActiveCampaign.node.ts b/packages/nodes-base/nodes/ActiveCampaign/ActiveCampaign.node.ts index d3beb6c7add8e..f2a5c2170e390 100644 --- a/packages/nodes-base/nodes/ActiveCampaign/ActiveCampaign.node.ts +++ b/packages/nodes-base/nodes/ActiveCampaign/ActiveCampaign.node.ts @@ -383,7 +383,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); const simple = this.getNodeParameter('simple', i, true) as boolean; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; @@ -470,7 +470,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; const simple = this.getNodeParameter('simple', i, true) as boolean; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -637,7 +637,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); const simple = this.getNodeParameter('simple', i, true) as boolean; if (returnAll === false) { @@ -695,7 +695,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; const simple = this.getNodeParameter('simple', i, true) as boolean; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -802,7 +802,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; const simple = this.getNodeParameter('simple', i, true) as boolean; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -901,7 +901,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; const simple = this.getNodeParameter('simple', i, true) as boolean; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -1001,7 +1001,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; const simple = this.getNodeParameter('simple', i, true) as boolean; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -1090,7 +1090,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; const simple = this.getNodeParameter('simple', i, true) as boolean; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -1136,7 +1136,7 @@ export class ActiveCampaign implements INodeType { requestMethod = 'GET'; const simple = this.getNodeParameter('simple', i, true) as boolean; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } diff --git a/packages/nodes-base/nodes/Affinity/Affinity.node.ts b/packages/nodes-base/nodes/Affinity/Affinity.node.ts index f0afa715a9937..b809436baac3e 100644 --- a/packages/nodes-base/nodes/Affinity/Affinity.node.ts +++ b/packages/nodes-base/nodes/Affinity/Affinity.node.ts @@ -162,7 +162,7 @@ export class Affinity implements INodeType { } //https://api-docs.affinity.co/#get-all-lists if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await affinityApiRequest.call(this, 'GET', `/lists`, {}, qs); if (returnAll === false) { const limit = this.getNodeParameter('limit', i) as number; @@ -201,7 +201,7 @@ export class Affinity implements INodeType { } //https://api-docs.affinity.co/#get-all-list-entries if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const listId = this.getNodeParameter('listId', i) as string; if (returnAll === true) { responseData = await affinityApiRequestAllItems.call( @@ -290,7 +290,7 @@ export class Affinity implements INodeType { } //https://api-docs.affinity.co/#search-for-persons if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.term) { qs.term = options.term as string; @@ -378,7 +378,7 @@ export class Affinity implements INodeType { } //https://api-docs.affinity.co/#search-for-organizations if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.term) { qs.term = options.term as string; diff --git a/packages/nodes-base/nodes/AgileCrm/AgileCrm.node.ts b/packages/nodes-base/nodes/AgileCrm/AgileCrm.node.ts index b941471c2b04e..235fc2ffa926a 100644 --- a/packages/nodes-base/nodes/AgileCrm/AgileCrm.node.ts +++ b/packages/nodes-base/nodes/AgileCrm/AgileCrm.node.ts @@ -112,7 +112,7 @@ export class AgileCrm implements INodeType { responseData = await agileCrmApiRequest.call(this, 'DELETE', endpoint, {}); } else if (operation === 'getAll') { const simple = this.getNodeParameter('simple', 0) as boolean; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const filterType = this.getNodeParameter('filterType', i) as string; const sort = this.getNodeParameter('options.sort.sort', i, {}) as { direction: string; @@ -195,7 +195,7 @@ export class AgileCrm implements INodeType { responseData = simplifyResponse(responseData); } } else if (operation === 'create') { - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const body: IContact = {}; const properties: IDataObject[] = []; @@ -347,7 +347,7 @@ export class AgileCrm implements INodeType { } else if (operation === 'update') { const contactId = this.getNodeParameter(idGetter, i) as string; const contactUpdatePayload: IContactUpdate = { id: contactId }; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const body: IContact = {}; const properties: IDataObject[] = []; @@ -510,7 +510,7 @@ export class AgileCrm implements INodeType { const endpoint = `api/opportunity/${contactId}`; responseData = await agileCrmApiRequest.call(this, 'DELETE', endpoint, {}); } else if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const endpoint = 'api/opportunity'; if (returnAll) { @@ -525,7 +525,7 @@ export class AgileCrm implements INodeType { }); } } else if (operation === 'create') { - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const body: IDeal = {}; @@ -565,7 +565,7 @@ export class AgileCrm implements INodeType { const endpoint = 'api/opportunity'; responseData = await agileCrmApiRequest.call(this, 'POST', endpoint, body); } else if (operation === 'update') { - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const body: IDeal = {}; diff --git a/packages/nodes-base/nodes/Airtable/Airtable.node.ts b/packages/nodes-base/nodes/Airtable/Airtable.node.ts index 188eadacd8ad9..9e85738e999c5 100644 --- a/packages/nodes-base/nodes/Airtable/Airtable.node.ts +++ b/packages/nodes-base/nodes/Airtable/Airtable.node.ts @@ -631,9 +631,9 @@ export class Airtable implements INodeType { requestMethod = 'GET'; endpoint = `${application}/${table}`; - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); - const downloadAttachments = this.getNodeParameter('downloadAttachments', 0) as boolean; + const downloadAttachments = this.getNodeParameter('downloadAttachments', 0); const additionalOptions = this.getNodeParameter('additionalOptions', 0, {}) as IDataObject; diff --git a/packages/nodes-base/nodes/ApiTemplateIo/ApiTemplateIo.node.ts b/packages/nodes-base/nodes/ApiTemplateIo/ApiTemplateIo.node.ts index 869dfe81b7de5..fda13bcd9092b 100644 --- a/packages/nodes-base/nodes/ApiTemplateIo/ApiTemplateIo.node.ts +++ b/packages/nodes-base/nodes/ApiTemplateIo/ApiTemplateIo.node.ts @@ -383,12 +383,12 @@ export class ApiTemplateIo implements INodeType { // image: create // ---------------------------------- - const download = this.getNodeParameter('download', 0) as boolean; + const download = this.getNodeParameter('download', 0); // https://docs.apitemplate.io/reference/api-reference.html#create-an-image-jpeg-and-png for (let i = 0; i < length; i++) { try { - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); let options: IDataObject = {}; if (download) { @@ -475,11 +475,11 @@ export class ApiTemplateIo implements INodeType { // ---------------------------------- // https://docs.apitemplate.io/reference/api-reference.html#create-a-pdf - const download = this.getNodeParameter('download', 0) as boolean; + const download = this.getNodeParameter('download', 0); for (let i = 0; i < length; i++) { try { - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); let options: IDataObject = {}; if (download) { diff --git a/packages/nodes-base/nodes/Asana/Asana.node.ts b/packages/nodes-base/nodes/Asana/Asana.node.ts index be65f8ac6e34d..51da262e01cc1 100644 --- a/packages/nodes-base/nodes/Asana/Asana.node.ts +++ b/packages/nodes-base/nodes/Asana/Asana.node.ts @@ -1953,7 +1953,7 @@ export class Asana implements INodeType { // ---------------------------------- const taskId = this.getNodeParameter('taskId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; @@ -2032,7 +2032,7 @@ export class Asana implements INodeType { // ---------------------------------- const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); requestMethod = 'GET'; endpoint = `/tasks`; @@ -2341,7 +2341,7 @@ export class Asana implements INodeType { // ---------------------------------- const workspaceId = this.getNodeParameter('workspace', i) as string; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); requestMethod = 'GET'; endpoint = `/projects`; diff --git a/packages/nodes-base/nodes/Automizy/Automizy.node.ts b/packages/nodes-base/nodes/Automizy/Automizy.node.ts index 8e2ada9d20489..a688393415ca1 100644 --- a/packages/nodes-base/nodes/Automizy/Automizy.node.ts +++ b/packages/nodes-base/nodes/Automizy/Automizy.node.ts @@ -192,7 +192,7 @@ export class Automizy implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const listId = this.getNodeParameter('listId', i) as string; @@ -302,7 +302,7 @@ export class Automizy implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; diff --git a/packages/nodes-base/nodes/Autopilot/Autopilot.node.ts b/packages/nodes-base/nodes/Autopilot/Autopilot.node.ts index c46dbb3da422a..34b8fdb47dc72 100644 --- a/packages/nodes-base/nodes/Autopilot/Autopilot.node.ts +++ b/packages/nodes-base/nodes/Autopilot/Autopilot.node.ts @@ -189,7 +189,7 @@ export class Autopilot implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; @@ -251,7 +251,7 @@ export class Autopilot implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const listId = this.getNodeParameter('listId', i) as string; @@ -284,7 +284,7 @@ export class Autopilot implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/Aws/CertificateManager/AwsCertificateManager.node.ts b/packages/nodes-base/nodes/Aws/CertificateManager/AwsCertificateManager.node.ts index 5a0b9a147bec3..41bc367cf52e4 100644 --- a/packages/nodes-base/nodes/Aws/CertificateManager/AwsCertificateManager.node.ts +++ b/packages/nodes-base/nodes/Aws/CertificateManager/AwsCertificateManager.node.ts @@ -104,7 +104,7 @@ export class AwsCertificateManager implements INodeType { //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html if (operation === 'getMany') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; const body: { Includes: IDataObject; CertificateStatuses: string[]; MaxItems: number } = { diff --git a/packages/nodes-base/nodes/Aws/DynamoDB/AwsDynamoDB.node.ts b/packages/nodes-base/nodes/Aws/DynamoDB/AwsDynamoDB.node.ts index 65ccd619c6471..108355162ecec 100644 --- a/packages/nodes-base/nodes/Aws/DynamoDB/AwsDynamoDB.node.ts +++ b/packages/nodes-base/nodes/Aws/DynamoDB/AwsDynamoDB.node.ts @@ -307,7 +307,7 @@ export class AwsDynamoDB implements INodeType { const eavUi = this.getNodeParameter('eavUi.eavValues', i, []) as IAttributeValueUi[]; const simple = this.getNodeParameter('simple', 0, false) as boolean; const select = this.getNodeParameter('select', 0) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const scan = this.getNodeParameter('scan', 0) as boolean; const eanUi = this.getNodeParameter( 'options.eanUi.eanValues', diff --git a/packages/nodes-base/nodes/Aws/ELB/AwsElb.node.ts b/packages/nodes-base/nodes/Aws/ELB/AwsElb.node.ts index 005dfd52abd16..afe737f864990 100644 --- a/packages/nodes-base/nodes/Aws/ELB/AwsElb.node.ts +++ b/packages/nodes-base/nodes/Aws/ELB/AwsElb.node.ts @@ -251,7 +251,7 @@ export class AwsElb implements INodeType { if (operation === 'getMany') { const params = ['Version=2015-12-01']; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const listenerId = this.getNodeParameter('listenerId', i) as string; @@ -385,7 +385,7 @@ export class AwsElb implements INodeType { if (operation === 'getMany') { const params = ['Version=2015-12-01']; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { const filters = this.getNodeParameter('filters', i) as IDataObject; diff --git a/packages/nodes-base/nodes/Aws/Rekognition/AwsRekognition.node.ts b/packages/nodes-base/nodes/Aws/Rekognition/AwsRekognition.node.ts index 3e6d7784cf829..5fc3fd83eba6f 100644 --- a/packages/nodes-base/nodes/Aws/Rekognition/AwsRekognition.node.ts +++ b/packages/nodes-base/nodes/Aws/Rekognition/AwsRekognition.node.ts @@ -412,7 +412,7 @@ export class AwsRekognition implements INodeType { body.Filters.WordFilter = keysTPascalCase(wordFilter); } - const binaryData = this.getNodeParameter('binaryData', 0) as boolean; + const binaryData = this.getNodeParameter('binaryData', 0); if (binaryData) { const binaryPropertyName = this.getNodeParameter('binaryPropertyName', 0) as string; diff --git a/packages/nodes-base/nodes/Aws/S3/AwsS3.node.ts b/packages/nodes-base/nodes/Aws/S3/AwsS3.node.ts index 54a585db03e33..f106facb6f613 100644 --- a/packages/nodes-base/nodes/Aws/S3/AwsS3.node.ts +++ b/packages/nodes-base/nodes/Aws/S3/AwsS3.node.ts @@ -172,7 +172,7 @@ export class AwsS3 implements INodeType { //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBuckets.html if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { responseData = await awsApiRequestSOAPAllItems.call( this, @@ -200,7 +200,7 @@ export class AwsS3 implements INodeType { //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html if (operation === 'search') { const bucketName = this.getNodeParameter('bucketName', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const additionalFields = this.getNodeParameter('additionalFields', 0) as IDataObject; if (additionalFields.prefix) { @@ -391,7 +391,7 @@ export class AwsS3 implements INodeType { //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html if (operation === 'getAll') { const bucketName = this.getNodeParameter('bucketName', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', 0) as IDataObject; if (options.folderKey) { @@ -656,7 +656,7 @@ export class AwsS3 implements INodeType { //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html if (operation === 'getAll') { const bucketName = this.getNodeParameter('bucketName', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', 0) as IDataObject; if (options.folderKey) { @@ -720,7 +720,7 @@ export class AwsS3 implements INodeType { if (operation === 'upload') { const bucketName = this.getNodeParameter('bucketName', i) as string; const fileName = this.getNodeParameter('fileName', i) as string; - const isBinaryData = this.getNodeParameter('binaryData', i) as boolean; + const isBinaryData = this.getNodeParameter('binaryData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const tagsValues = (this.getNodeParameter('tagsUi', i) as IDataObject) .tagsValues as IDataObject[]; diff --git a/packages/nodes-base/nodes/Aws/SES/AwsSes.node.ts b/packages/nodes-base/nodes/Aws/SES/AwsSes.node.ts index 4d61e0de28a8b..014fb6dc884ca 100644 --- a/packages/nodes-base/nodes/Aws/SES/AwsSes.node.ts +++ b/packages/nodes-base/nodes/Aws/SES/AwsSes.node.ts @@ -909,7 +909,7 @@ export class AwsSes implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await awsApiRequestSOAPAllItems.call( @@ -1237,7 +1237,7 @@ export class AwsSes implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await awsApiRequestSOAPAllItems.call( diff --git a/packages/nodes-base/nodes/Aws/Transcribe/AwsTranscribe.node.ts b/packages/nodes-base/nodes/Aws/Transcribe/AwsTranscribe.node.ts index 528e02656ae82..48d4024aefb72 100644 --- a/packages/nodes-base/nodes/Aws/Transcribe/AwsTranscribe.node.ts +++ b/packages/nodes-base/nodes/Aws/Transcribe/AwsTranscribe.node.ts @@ -490,7 +490,7 @@ export class AwsTranscribe implements INodeType { } //https://docs.aws.amazon.com/transcribe/latest/dg/API_ListTranscriptionJobs.html if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; const action = 'Transcribe.ListTranscriptionJobs'; const body: IDataObject = {}; diff --git a/packages/nodes-base/nodes/Beeminder/Beeminder.node.ts b/packages/nodes-base/nodes/Beeminder/Beeminder.node.ts index 286b40aaf2c0b..676a21f8fe918 100644 --- a/packages/nodes-base/nodes/Beeminder/Beeminder.node.ts +++ b/packages/nodes-base/nodes/Beeminder/Beeminder.node.ts @@ -323,7 +323,7 @@ export class Beeminder implements INodeType { ); returnData.push(...executionData); } else if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as INodeParameters; const data: IDataObject = { goalName, diff --git a/packages/nodes-base/nodes/Bitwarden/GenericFunctions.ts b/packages/nodes-base/nodes/Bitwarden/GenericFunctions.ts index 97241605d141a..08030bf02ef69 100644 --- a/packages/nodes-base/nodes/Bitwarden/GenericFunctions.ts +++ b/packages/nodes-base/nodes/Bitwarden/GenericFunctions.ts @@ -98,7 +98,7 @@ export async function handleGetAll( token: string, ) { const responseData = await bitwardenApiRequest.call(this, method, endpoint, qs, body, token); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { return responseData.data; diff --git a/packages/nodes-base/nodes/Box/Box.node.ts b/packages/nodes-base/nodes/Box/Box.node.ts index 1f9b49fdde615..91734cf76ebec 100644 --- a/packages/nodes-base/nodes/Box/Box.node.ts +++ b/packages/nodes-base/nodes/Box/Box.node.ts @@ -172,7 +172,7 @@ export class Box implements INodeType { // https://developer.box.com/reference/get-search/ if (operation === 'search') { const query = this.getNodeParameter('query', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const timezone = this.getTimezone(); qs.type = 'file'; @@ -267,7 +267,7 @@ export class Box implements INodeType { // https://developer.box.com/reference/post-files-content if (operation === 'upload') { const parentId = this.getNodeParameter('parentId', i) as string; - const isBinaryData = this.getNodeParameter('binaryData', i) as boolean; + const isBinaryData = this.getNodeParameter('binaryData', i); const fileName = this.getNodeParameter('fileName', i) as string; const attributes: IDataObject = {}; @@ -406,7 +406,7 @@ export class Box implements INodeType { // https://developer.box.com/reference/get-search/ if (operation === 'search') { const query = this.getNodeParameter('query', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const timezone = this.getTimezone(); qs.type = 'folder'; diff --git a/packages/nodes-base/nodes/Brandfetch/Brandfetch.node.ts b/packages/nodes-base/nodes/Brandfetch/Brandfetch.node.ts index dcd932bb8b818..407dcd2948ddf 100644 --- a/packages/nodes-base/nodes/Brandfetch/Brandfetch.node.ts +++ b/packages/nodes-base/nodes/Brandfetch/Brandfetch.node.ts @@ -151,7 +151,7 @@ export class Brandfetch implements INodeType { try { if (operation === 'logo') { const domain = this.getNodeParameter('domain', i) as string; - const download = this.getNodeParameter('download', i) as boolean; + const download = this.getNodeParameter('download', i); const body: IDataObject = { domain, diff --git a/packages/nodes-base/nodes/Bubble/Bubble.node.ts b/packages/nodes-base/nodes/Bubble/Bubble.node.ts index 8058b3f855a5c..500a4ea850e5d 100644 --- a/packages/nodes-base/nodes/Bubble/Bubble.node.ts +++ b/packages/nodes-base/nodes/Bubble/Bubble.node.ts @@ -115,7 +115,7 @@ export class Bubble implements INodeType { // object: getAll // ---------------------------------- - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const typeNameInput = this.getNodeParameter('typeName', i) as string; const typeName = typeNameInput.replace(/\s/g, '').toLowerCase(); diff --git a/packages/nodes-base/nodes/CircleCi/CircleCi.node.ts b/packages/nodes-base/nodes/CircleCi/CircleCi.node.ts index 49a1b02c08c85..d0ab38b03ef3c 100644 --- a/packages/nodes-base/nodes/CircleCi/CircleCi.node.ts +++ b/packages/nodes-base/nodes/CircleCi/CircleCi.node.ts @@ -76,7 +76,7 @@ export class CircleCi implements INodeType { if (operation === 'getAll') { const vcs = this.getNodeParameter('vcs', i) as string; const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); let slug = this.getNodeParameter('projectSlug', i) as string; slug = slug.replace(new RegExp(/\//g), '%2F'); diff --git a/packages/nodes-base/nodes/Cisco/Webex/CiscoWebex.node.ts b/packages/nodes-base/nodes/Cisco/Webex/CiscoWebex.node.ts index 47adfa73f5d44..48d17ea34e45a 100644 --- a/packages/nodes-base/nodes/Cisco/Webex/CiscoWebex.node.ts +++ b/packages/nodes-base/nodes/Cisco/Webex/CiscoWebex.node.ts @@ -254,7 +254,7 @@ export class CiscoWebex implements INodeType { roomId: this.getNodeParameter('roomId', i), }; const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (Object.keys(filters).length) { Object.assign(qs, filters); @@ -401,7 +401,7 @@ export class CiscoWebex implements INodeType { if (operation === 'getAll') { const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const qs: IDataObject = { ...filters, @@ -543,7 +543,7 @@ export class CiscoWebex implements INodeType { // try { // const meetingId = this.getNodeParameter('meetingId', i) as string; // const filters = this.getNodeParameter('filters', i) as IDataObject; - // const returnAll = this.getNodeParameter('returnAll', i) as boolean; + // const returnAll = this.getNodeParameter('returnAll', i); // const qs: IDataObject = { // meetingId, diff --git a/packages/nodes-base/nodes/ClickUp/ClickUp.node.ts b/packages/nodes-base/nodes/ClickUp/ClickUp.node.ts index 35dd2e9cf7727..75c12c6eb10c6 100644 --- a/packages/nodes-base/nodes/ClickUp/ClickUp.node.ts +++ b/packages/nodes-base/nodes/ClickUp/ClickUp.node.ts @@ -1017,7 +1017,7 @@ export class ClickUp implements INodeType { responseData = await clickupApiRequest.call(this, 'GET', `/task/${taskId}`); } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.archived) { qs.archived = filters.archived as boolean; @@ -1101,7 +1101,7 @@ export class ClickUp implements INodeType { } if (operation === 'member') { const taskId = this.getNodeParameter('id', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await clickupApiRequest.call( this, @@ -1276,7 +1276,7 @@ export class ClickUp implements INodeType { } if (operation === 'getAll') { const teamId = this.getNodeParameter('team', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; const timezone = this.getTimezone(); Object.assign(qs, filters); @@ -1410,7 +1410,7 @@ export class ClickUp implements INodeType { } if (operation === 'getAll') { const teamId = this.getNodeParameter('team', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await clickupApiRequest.call( this, 'GET', @@ -1473,7 +1473,7 @@ export class ClickUp implements INodeType { } if (operation === 'getAll') { const spaceId = this.getNodeParameter('space', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await clickupApiRequest.call(this, 'GET', `/space/${spaceId}/tag`); responseData = responseData.tags; if (returnAll === false) { @@ -1544,7 +1544,7 @@ export class ClickUp implements INodeType { } if (operation === 'member') { const listId = this.getNodeParameter('id', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await clickupApiRequest.call( this, diff --git a/packages/nodes-base/nodes/Clockify/Clockify.node.ts b/packages/nodes-base/nodes/Clockify/Clockify.node.ts index da166ce1f238d..51b10be8a2390 100644 --- a/packages/nodes-base/nodes/Clockify/Clockify.node.ts +++ b/packages/nodes-base/nodes/Clockify/Clockify.node.ts @@ -320,7 +320,7 @@ export class Clockify implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const workspaceId = this.getNodeParameter('workspaceId', i) as string; @@ -410,7 +410,7 @@ export class Clockify implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const workspaceId = this.getNodeParameter('workspaceId', i) as string; @@ -504,7 +504,7 @@ export class Clockify implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const workspaceId = this.getNodeParameter('workspaceId', i) as string; @@ -619,7 +619,7 @@ export class Clockify implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const workspaceId = this.getNodeParameter('workspaceId', i) as string; @@ -792,7 +792,7 @@ export class Clockify implements INodeType { if (resource === 'user') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const workspaceId = this.getNodeParameter('workspaceId', i) as string; @@ -826,7 +826,7 @@ export class Clockify implements INodeType { if (resource === 'workspace') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await clockifyApiRequest.call(this, 'GET', '/workspaces', {}, qs); if (!returnAll) { qs.limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/Cloudflare/Cloudflare.node.ts b/packages/nodes-base/nodes/Cloudflare/Cloudflare.node.ts index 862332272b14a..2178b23fd03d5 100644 --- a/packages/nodes-base/nodes/Cloudflare/Cloudflare.node.ts +++ b/packages/nodes-base/nodes/Cloudflare/Cloudflare.node.ts @@ -109,7 +109,7 @@ export class Cloudflare implements INodeType { //https://api.cloudflare.com/#zone-level-authenticated-origin-pulls-list-certificates if (operation === 'getMany') { const zoneId = this.getNodeParameter('zoneId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i, {}) as IDataObject; Object.assign(qs, filters); diff --git a/packages/nodes-base/nodes/Cockpit/Cockpit.node.ts b/packages/nodes-base/nodes/Cockpit/Cockpit.node.ts index 89b7975599c20..75bb29faef2f1 100644 --- a/packages/nodes-base/nodes/Cockpit/Cockpit.node.ts +++ b/packages/nodes-base/nodes/Cockpit/Cockpit.node.ts @@ -118,7 +118,7 @@ export class Cockpit implements INodeType { responseData = await createCollectionEntry.call(this, collectionName, data); } else if (operation === 'getAll') { const options = this.getNodeParameter('options', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { options.limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/Coda/Coda.node.ts b/packages/nodes-base/nodes/Coda/Coda.node.ts index b459d3feb1496..5010be2dd3ca3 100644 --- a/packages/nodes-base/nodes/Coda/Coda.node.ts +++ b/packages/nodes-base/nodes/Coda/Coda.node.ts @@ -360,7 +360,7 @@ export class Coda implements INodeType { // https://coda.io/developers/apis/v1beta1#operation/listRows if (operation === 'getAllRows') { const docId = this.getNodeParameter('docId', 0) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const tableId = this.getNodeParameter('tableId', 0) as string; const options = this.getNodeParameter('options', 0) as IDataObject; const endpoint = `/docs/${docId}/tables/${tableId}/rows`; @@ -503,7 +503,7 @@ export class Coda implements INodeType { if (operation === 'getAllColumns') { for (let i = 0; i < items.length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const docId = this.getNodeParameter('docId', i) as string; const tableId = this.getNodeParameter('tableId', i) as string; const endpoint = `/docs/${docId}/tables/${tableId}/columns`; @@ -566,7 +566,7 @@ export class Coda implements INodeType { if (operation === 'getAll') { for (let i = 0; i < items.length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const docId = this.getNodeParameter('docId', i) as string; const endpoint = `/docs/${docId}/formulas`; if (returnAll) { @@ -628,7 +628,7 @@ export class Coda implements INodeType { if (operation === 'getAll') { for (let i = 0; i < items.length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const docId = this.getNodeParameter('docId', i) as string; const endpoint = `/docs/${docId}/controls`; if (returnAll) { @@ -678,7 +678,7 @@ export class Coda implements INodeType { if (operation === 'getAll') { for (let i = 0; i < items.length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const docId = this.getNodeParameter('docId', i) as string; const endpoint = `/docs/${docId}/tables?tableTypes=view`; if (returnAll) { @@ -709,7 +709,7 @@ export class Coda implements INodeType { } if (operation === 'getAllViewRows') { const docId = this.getNodeParameter('docId', 0) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const viewId = this.getNodeParameter('viewId', 0) as string; const options = this.getNodeParameter('options', 0) as IDataObject; const endpoint = `/docs/${docId}/tables/${viewId}/rows`; @@ -821,7 +821,7 @@ export class Coda implements INodeType { if (operation === 'getAllViewColumns') { for (let i = 0; i < items.length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const docId = this.getNodeParameter('docId', i) as string; const viewId = this.getNodeParameter('viewId', i) as string; const endpoint = `/docs/${docId}/tables/${viewId}/columns`; diff --git a/packages/nodes-base/nodes/CoinGecko/CoinGecko.node.ts b/packages/nodes-base/nodes/CoinGecko/CoinGecko.node.ts index af348eec442cf..5ce1095f002ed 100644 --- a/packages/nodes-base/nodes/CoinGecko/CoinGecko.node.ts +++ b/packages/nodes-base/nodes/CoinGecko/CoinGecko.node.ts @@ -191,7 +191,7 @@ export class CoinGecko implements INodeType { } //https://www.coingecko.com/api/documentations/v3#/coins/get_coins_list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); let limit; @@ -205,7 +205,7 @@ export class CoinGecko implements INodeType { //https://www.coingecko.com/api/documentations/v3#/coins/get_coins_list if (operation === 'market') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const baseCurrency = this.getNodeParameter('baseCurrency', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; @@ -272,7 +272,7 @@ export class CoinGecko implements INodeType { //https://www.coingecko.com/api/documentations/v3#/coins/get_coins__id__tickers if (operation === 'ticker') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const coinId = this.getNodeParameter('coinId', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; @@ -410,7 +410,7 @@ export class CoinGecko implements INodeType { if (resource === 'event') { //https://www.coingecko.com/api/documentations/v3#/events/get_events if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; Object.assign(qs, options); diff --git a/packages/nodes-base/nodes/Contentful/Contentful.node.ts b/packages/nodes-base/nodes/Contentful/Contentful.node.ts index c9bb422f9acda..143d84a43075f 100644 --- a/packages/nodes-base/nodes/Contentful/Contentful.node.ts +++ b/packages/nodes-base/nodes/Contentful/Contentful.node.ts @@ -148,7 +148,7 @@ export class Contentful implements INodeType { } else if (operation === 'getAll') { const credentials = await this.getCredentials('contentfulApi'); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const rawData = additionalFields.rawData; @@ -247,7 +247,7 @@ export class Contentful implements INodeType { } else if (operation === 'getAll') { const credentials = await this.getCredentials('contentfulApi'); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const rawData = additionalFields.rawData; @@ -326,7 +326,7 @@ export class Contentful implements INodeType { if (operation === 'getAll') { const credentials = await this.getCredentials('contentfulApi'); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const env = this.getNodeParameter('environmentId', i) as string; diff --git a/packages/nodes-base/nodes/ConvertKit/ConvertKit.node.ts b/packages/nodes-base/nodes/ConvertKit/ConvertKit.node.ts index 5b5a1040559c3..bfa1581f10a40 100644 --- a/packages/nodes-base/nodes/ConvertKit/ConvertKit.node.ts +++ b/packages/nodes-base/nodes/ConvertKit/ConvertKit.node.ts @@ -187,7 +187,7 @@ export class ConvertKit implements INodeType { responseData = await convertKitApiRequest.call(this, 'GET', `/custom_fields/${id}`); } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await convertKitApiRequest.call(this, 'GET', `/custom_fields`); @@ -254,7 +254,7 @@ export class ConvertKit implements INodeType { responseData = subscription; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await convertKitApiRequest.call(this, 'GET', `/forms`); @@ -269,7 +269,7 @@ export class ConvertKit implements INodeType { if (operation === 'getSubscriptions') { const formId = this.getNodeParameter('id', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; @@ -337,7 +337,7 @@ export class ConvertKit implements INodeType { responseData = subscription; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await convertKitApiRequest.call(this, 'GET', `/sequences`); @@ -352,7 +352,7 @@ export class ConvertKit implements INodeType { if (operation === 'getSubscriptions') { const sequenceId = this.getNodeParameter('id', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; @@ -392,7 +392,7 @@ export class ConvertKit implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await convertKitApiRequest.call(this, 'GET', `/tags`); @@ -447,7 +447,7 @@ export class ConvertKit implements INodeType { if (operation === 'getAll') { const tagId = this.getNodeParameter('tagId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await convertKitApiRequest.call( this, diff --git a/packages/nodes-base/nodes/CustomerIo/CustomerIo.node.ts b/packages/nodes-base/nodes/CustomerIo/CustomerIo.node.ts index 581b166ebefe6..9a982d3d4e796 100644 --- a/packages/nodes-base/nodes/CustomerIo/CustomerIo.node.ts +++ b/packages/nodes-base/nodes/CustomerIo/CustomerIo.node.ts @@ -101,7 +101,7 @@ export class CustomerIo implements INodeType { if (operation === 'getMetrics') { const campaignId = this.getNodeParameter('campaignId', i) as number; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const additionalFieldsJson = this.getNodeParameter( @@ -148,7 +148,7 @@ export class CustomerIo implements INodeType { if (resource === 'customer') { if (operation === 'upsert') { const id = this.getNodeParameter('id', i) as number; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const additionalFieldsJson = this.getNodeParameter( @@ -215,7 +215,7 @@ export class CustomerIo implements INodeType { if (operation === 'track') { const customerId = this.getNodeParameter('customerId', i) as number; const eventName = this.getNodeParameter('eventName', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); body.name = eventName; @@ -264,7 +264,7 @@ export class CustomerIo implements INodeType { if (operation === 'trackAnonymous') { const eventName = this.getNodeParameter('eventName', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); body.name = eventName; diff --git a/packages/nodes-base/nodes/Demio/Demio.node.ts b/packages/nodes-base/nodes/Demio/Demio.node.ts index 006cddcbcae9b..f3f35f3b45ff1 100644 --- a/packages/nodes-base/nodes/Demio/Demio.node.ts +++ b/packages/nodes-base/nodes/Demio/Demio.node.ts @@ -132,7 +132,7 @@ export class Demio implements INodeType { } if (operation === 'getAll') { const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); Object.assign(qs, filters); diff --git a/packages/nodes-base/nodes/Discourse/Discourse.node.ts b/packages/nodes-base/nodes/Discourse/Discourse.node.ts index 2ddfaf2f320dd..14e191da666a2 100644 --- a/packages/nodes-base/nodes/Discourse/Discourse.node.ts +++ b/packages/nodes-base/nodes/Discourse/Discourse.node.ts @@ -137,7 +137,7 @@ export class Discourse implements INodeType { } //https://docs.discourse.org/#tag/Categories/paths/~1categories.json/get if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await discourseApiRequest.call(this, 'GET', `/categories.json`, {}, qs); @@ -197,7 +197,7 @@ export class Discourse implements INodeType { } //https://docs.discourse.org/#tag/Groups/paths/~1groups.json/get if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await discourseApiRequest.call(this, 'GET', `/groups.json`, {}, qs); @@ -247,7 +247,7 @@ export class Discourse implements INodeType { } //https://docs.discourse.org/#tag/Posts/paths/~1posts.json/get if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const limit = this.getNodeParameter('limit', i, 0) as number; responseData = await discourseApiRequest.call(this, 'GET', `/posts.json`, {}, qs); @@ -370,7 +370,7 @@ export class Discourse implements INodeType { } //https://docs.discourse.org/#tag/Users/paths/~1admin~1users~1{id}.json/delete if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const flag = this.getNodeParameter('flag', i) as boolean; responseData = await discourseApiRequest.call( diff --git a/packages/nodes-base/nodes/Disqus/Disqus.node.ts b/packages/nodes-base/nodes/Disqus/Disqus.node.ts index e2831ae80f2be..12b04d9ae631d 100644 --- a/packages/nodes-base/nodes/Disqus/Disqus.node.ts +++ b/packages/nodes-base/nodes/Disqus/Disqus.node.ts @@ -625,7 +625,7 @@ export class Disqus implements INodeType { const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; Object.assign(qs, additionalFields); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs.forum = id; qs.limit = 100; @@ -662,7 +662,7 @@ export class Disqus implements INodeType { endpoint = 'forums/listCategories.json'; const id = this.getNodeParameter('id', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; Object.assign(qs, additionalFields); @@ -707,7 +707,7 @@ export class Disqus implements INodeType { endpoint = 'forums/listThreads.json'; const id = this.getNodeParameter('id', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs.forum = id; qs.limit = 100; diff --git a/packages/nodes-base/nodes/Dropbox/Dropbox.node.ts b/packages/nodes-base/nodes/Dropbox/Dropbox.node.ts index e588d091514b6..f2e455d57189a 100644 --- a/packages/nodes-base/nodes/Dropbox/Dropbox.node.ts +++ b/packages/nodes-base/nodes/Dropbox/Dropbox.node.ts @@ -802,7 +802,7 @@ export class Dropbox implements INodeType { // list // ---------------------------------- - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); const filters = this.getNodeParameter('filters', i) as IDataObject; @@ -829,7 +829,7 @@ export class Dropbox implements INodeType { // query // ---------------------------------- - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); simple = this.getNodeParameter('simple', 0) as boolean; diff --git a/packages/nodes-base/nodes/ERPNext/ERPNext.node.ts b/packages/nodes-base/nodes/ERPNext/ERPNext.node.ts index 4d3abd995dda6..ad09d8f92c024 100644 --- a/packages/nodes-base/nodes/ERPNext/ERPNext.node.ts +++ b/packages/nodes-base/nodes/ERPNext/ERPNext.node.ts @@ -185,7 +185,7 @@ export class ERPNext implements INodeType { ); } - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { const limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/Egoi/Egoi.node.ts b/packages/nodes-base/nodes/Egoi/Egoi.node.ts index e064503658363..109eb75c4ad3b 100644 --- a/packages/nodes-base/nodes/Egoi/Egoi.node.ts +++ b/packages/nodes-base/nodes/Egoi/Egoi.node.ts @@ -551,7 +551,7 @@ export class Egoi implements INodeType { const email = this.getNodeParameter('email', i) as string; - const resolveData = this.getNodeParameter('resolveData', i) as boolean; + const resolveData = this.getNodeParameter('resolveData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; @@ -648,7 +648,7 @@ export class Egoi implements INodeType { if (operation === 'getAll') { const listId = this.getNodeParameter('list', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const simple = this.getNodeParameter('simple', i) as boolean; @@ -682,7 +682,7 @@ export class Egoi implements INodeType { if (operation === 'update') { const listId = this.getNodeParameter('list', i) as string; const contactId = this.getNodeParameter('contactId', i) as string; - const resolveData = this.getNodeParameter('resolveData', i) as boolean; + const resolveData = this.getNodeParameter('resolveData', i); const updateFields = this.getNodeParameter('updateFields', i) as IDataObject; const body: ICreateMemberBody = { diff --git a/packages/nodes-base/nodes/Elastic/ElasticSecurity/GenericFunctions.ts b/packages/nodes-base/nodes/Elastic/ElasticSecurity/GenericFunctions.ts index 0f30fa2f36a6c..a4e3130758b2a 100644 --- a/packages/nodes-base/nodes/Elastic/ElasticSecurity/GenericFunctions.ts +++ b/packages/nodes-base/nodes/Elastic/ElasticSecurity/GenericFunctions.ts @@ -86,7 +86,7 @@ export async function handleListing( body: IDataObject = {}, qs: IDataObject = {}, ) { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { return await elasticSecurityApiRequestAllItems.call(this, method, endpoint, body, qs); diff --git a/packages/nodes-base/nodes/Flow/Flow.node.ts b/packages/nodes-base/nodes/Flow/Flow.node.ts index 43875e1f4b902..526971f9978e2 100644 --- a/packages/nodes-base/nodes/Flow/Flow.node.ts +++ b/packages/nodes-base/nodes/Flow/Flow.node.ts @@ -211,7 +211,7 @@ export class Flow implements INodeType { } //https://developer.getflow.com/api/#tasks_get-tasks if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; qs.organization_id = credentials.organizationId as number; if (filters.include) { diff --git a/packages/nodes-base/nodes/Freshdesk/Freshdesk.node.ts b/packages/nodes-base/nodes/Freshdesk/Freshdesk.node.ts index 03123960dc388..b7293b96715e8 100644 --- a/packages/nodes-base/nodes/Freshdesk/Freshdesk.node.ts +++ b/packages/nodes-base/nodes/Freshdesk/Freshdesk.node.ts @@ -1285,7 +1285,7 @@ export class Freshdesk implements INodeType { } //https://developers.freshdesk.com/api/#list_all_tickets if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.requesterId) { qs.requester_id = options.requesterId as string; diff --git a/packages/nodes-base/nodes/Freshservice/GenericFunctions.ts b/packages/nodes-base/nodes/Freshservice/GenericFunctions.ts index 9db2010110cb4..b2ce3a411d933 100644 --- a/packages/nodes-base/nodes/Freshservice/GenericFunctions.ts +++ b/packages/nodes-base/nodes/Freshservice/GenericFunctions.ts @@ -99,7 +99,7 @@ export async function handleListing( body: IDataObject = {}, qs: IDataObject = {}, ) { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { return await freshserviceApiRequestAllItems.call(this, method, endpoint, body, qs); diff --git a/packages/nodes-base/nodes/FreshworksCrm/GenericFunctions.ts b/packages/nodes-base/nodes/FreshworksCrm/GenericFunctions.ts index 38992dfeae25c..9952662233e21 100644 --- a/packages/nodes-base/nodes/FreshworksCrm/GenericFunctions.ts +++ b/packages/nodes-base/nodes/FreshworksCrm/GenericFunctions.ts @@ -104,7 +104,7 @@ export async function handleListing( body: IDataObject = {}, qs: IDataObject = {}, ) { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { return await freshworksCrmApiRequestAllItems.call(this, method, endpoint, body, qs); diff --git a/packages/nodes-base/nodes/GetResponse/GetResponse.node.ts b/packages/nodes-base/nodes/GetResponse/GetResponse.node.ts index 1b0e28b60279f..be638a67e6cf0 100644 --- a/packages/nodes-base/nodes/GetResponse/GetResponse.node.ts +++ b/packages/nodes-base/nodes/GetResponse/GetResponse.node.ts @@ -211,7 +211,7 @@ export class GetResponse implements INodeType { } //https://apireference.getresponse.com/?_ga=2.160836350.2102802044.1604719933-1897033509.1604598019#operation/getContactList if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; diff --git a/packages/nodes-base/nodes/Ghost/Ghost.node.ts b/packages/nodes-base/nodes/Ghost/Ghost.node.ts index dff7d61056f1c..2e222217ca53c 100644 --- a/packages/nodes-base/nodes/Ghost/Ghost.node.ts +++ b/packages/nodes-base/nodes/Ghost/Ghost.node.ts @@ -154,7 +154,7 @@ export class Ghost implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; @@ -259,7 +259,7 @@ export class Ghost implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; diff --git a/packages/nodes-base/nodes/Github/Github.node.ts b/packages/nodes-base/nodes/Github/Github.node.ts index c52caee54e498..afc44513722ad 100644 --- a/packages/nodes-base/nodes/Github/Github.node.ts +++ b/packages/nodes-base/nodes/Github/Github.node.ts @@ -1931,7 +1931,7 @@ export class Github implements INodeType { endpoint = `/repos/${owner}/${repository}/releases`; - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === false) { qs.per_page = this.getNodeParameter('limit', 0) as number; @@ -1994,7 +1994,7 @@ export class Github implements INodeType { endpoint = `/repos/${owner}/${repository}/issues`; - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === false) { qs.per_page = this.getNodeParameter('limit', 0) as number; @@ -2018,7 +2018,7 @@ export class Github implements INodeType { // ---------------------------------- requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); const pullRequestNumber = this.getNodeParameter('pullRequestNumber', i) as string; @@ -2066,7 +2066,7 @@ export class Github implements INodeType { endpoint = `/users/${owner}/repos`; - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === false) { qs.per_page = this.getNodeParameter('limit', 0) as number; @@ -2090,7 +2090,7 @@ export class Github implements INodeType { requestMethod = 'GET'; endpoint = `/orgs/${owner}/repos`; - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === false) { qs.per_page = this.getNodeParameter('limit', 0) as number; diff --git a/packages/nodes-base/nodes/Gitlab/Gitlab.node.ts b/packages/nodes-base/nodes/Gitlab/Gitlab.node.ts index a3571395b73da..a2802e5c5788a 100644 --- a/packages/nodes-base/nodes/Gitlab/Gitlab.node.ts +++ b/packages/nodes-base/nodes/Gitlab/Gitlab.node.ts @@ -1175,7 +1175,7 @@ export class Gitlab implements INodeType { qs = this.getNodeParameter('additionalFields', i, {}) as IDataObject; - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === false) { qs.per_page = this.getNodeParameter('limit', 0) as number; diff --git a/packages/nodes-base/nodes/GoToWebinar/GenericFunctions.ts b/packages/nodes-base/nodes/GoToWebinar/GenericFunctions.ts index 134111758964e..e3164cf8e0beb 100644 --- a/packages/nodes-base/nodes/GoToWebinar/GenericFunctions.ts +++ b/packages/nodes-base/nodes/GoToWebinar/GenericFunctions.ts @@ -123,7 +123,7 @@ export async function handleGetAll( body: IDataObject, resource: string, ) { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { qs.limit = this.getNodeParameter('limit', 0) as number; diff --git a/packages/nodes-base/nodes/GoToWebinar/GoToWebinar.node.ts b/packages/nodes-base/nodes/GoToWebinar/GoToWebinar.node.ts index 16272c07298da..de9dbd9081d24 100644 --- a/packages/nodes-base/nodes/GoToWebinar/GoToWebinar.node.ts +++ b/packages/nodes-base/nodes/GoToWebinar/GoToWebinar.node.ts @@ -443,7 +443,7 @@ export class GoToWebinar implements INodeType { const qs = {} as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { qs.limit = this.getNodeParameter('limit', 0) as number; @@ -563,7 +563,7 @@ export class GoToWebinar implements INodeType { const qs = {} as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { qs.limit = this.getNodeParameter('limit', 0) as number; diff --git a/packages/nodes-base/nodes/Google/Analytics/GoogleAnalytics.node.ts b/packages/nodes-base/nodes/Google/Analytics/GoogleAnalytics.node.ts index 2e5e9e7d60af8..f541cdbbb2a84 100644 --- a/packages/nodes-base/nodes/Google/Analytics/GoogleAnalytics.node.ts +++ b/packages/nodes-base/nodes/Google/Analytics/GoogleAnalytics.node.ts @@ -156,7 +156,7 @@ export class GoogleAnalytics implements INodeType { method = 'POST'; endpoint = '/v4/reports:batchGet'; const viewId = this.getNodeParameter('viewId', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const simple = this.getNodeParameter('simple', i) as boolean; @@ -249,7 +249,7 @@ export class GoogleAnalytics implements INodeType { endpoint = '/v4/userActivity:search'; const viewId = this.getNodeParameter('viewId', i); const userId = this.getNodeParameter('userId', i); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const body: IDataObject = { viewId, diff --git a/packages/nodes-base/nodes/Google/BigQuery/GoogleBigQuery.node.ts b/packages/nodes-base/nodes/Google/BigQuery/GoogleBigQuery.node.ts index 7e563429b0831..6434b86efbd89 100644 --- a/packages/nodes-base/nodes/Google/BigQuery/GoogleBigQuery.node.ts +++ b/packages/nodes-base/nodes/Google/BigQuery/GoogleBigQuery.node.ts @@ -213,7 +213,7 @@ export class GoogleBigQuery implements INodeType { // https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/get - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const projectId = this.getNodeParameter('projectId', 0) as string; const datasetId = this.getNodeParameter('datasetId', 0) as string; const tableId = this.getNodeParameter('tableId', 0) as string; diff --git a/packages/nodes-base/nodes/Google/Books/GoogleBooks.node.ts b/packages/nodes-base/nodes/Google/Books/GoogleBooks.node.ts index 52ce0db749361..058ce1bc9e9c4 100644 --- a/packages/nodes-base/nodes/Google/Books/GoogleBooks.node.ts +++ b/packages/nodes-base/nodes/Google/Books/GoogleBooks.node.ts @@ -358,7 +358,7 @@ export class GoogleBooks implements INodeType { responseData = await googleApiRequest.call(this, 'GET', `v1/volumes/${volumeId}`, {}); } else if (operation === 'getAll') { const searchQuery = this.getNodeParameter('searchQuery', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await googleApiRequestAllItems.call( this, @@ -396,7 +396,7 @@ export class GoogleBooks implements INodeType { responseData = await googleApiRequest.call(this, 'GET', endpoint, {}); } else if (operation === 'getAll') { const myLibrary = this.getNodeParameter('myLibrary', i) as boolean; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); let endpoint; if (myLibrary === false) { const userId = this.getNodeParameter('userId', i) as string; @@ -446,7 +446,7 @@ export class GoogleBooks implements INodeType { if (operation === 'getAll') { const shelfId = this.getNodeParameter('shelfId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const myLibrary = this.getNodeParameter('myLibrary', i) as boolean; let endpoint; if (myLibrary === false) { diff --git a/packages/nodes-base/nodes/Google/Calendar/GoogleCalendar.node.ts b/packages/nodes-base/nodes/Google/Calendar/GoogleCalendar.node.ts index 57f7318370f2c..a2ff976ec73c4 100644 --- a/packages/nodes-base/nodes/Google/Calendar/GoogleCalendar.node.ts +++ b/packages/nodes-base/nodes/Google/Calendar/GoogleCalendar.node.ts @@ -386,7 +386,7 @@ export class GoogleCalendar implements INodeType { } //https://developers.google.com/calendar/v3/reference/events/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const calendarId = this.getNodeParameter('calendar', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; if (options.iCalUID) { diff --git a/packages/nodes-base/nodes/Google/Chat/GoogleChat.node.ts b/packages/nodes-base/nodes/Google/Chat/GoogleChat.node.ts index 33298144e2801..62cb64fbcb7a3 100644 --- a/packages/nodes-base/nodes/Google/Chat/GoogleChat.node.ts +++ b/packages/nodes-base/nodes/Google/Chat/GoogleChat.node.ts @@ -268,7 +268,7 @@ export class GoogleChat implements INodeType { // https://developers.google.com/chat/reference/rest/v1/spaces/list - const returnAll = this.getNodeParameter('returnAll', 0) as IDataObject; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { responseData = await googleApiRequestAllItems.call( this, @@ -304,7 +304,7 @@ export class GoogleChat implements INodeType { const spaceId = this.getNodeParameter('spaceId', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as IDataObject; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { responseData = await googleApiRequestAllItems.call( this, @@ -348,7 +348,7 @@ export class GoogleChat implements INodeType { } let message: IMessage = {}; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const messageJson = this.getNodeParameter('messageJson', i); @@ -423,7 +423,7 @@ export class GoogleChat implements INodeType { const messageId = this.getNodeParameter('messageId', i) as string; let message: IMessage = {}; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const updateFieldsJson = this.getNodeParameter('updateFieldsJson', i); @@ -498,7 +498,7 @@ export class GoogleChat implements INodeType { } let message: IMessage = {}; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const messageJson = this.getNodeParameter('messageJson', i); diff --git a/packages/nodes-base/nodes/Google/Contacts/GoogleContacts.node.ts b/packages/nodes-base/nodes/Google/Contacts/GoogleContacts.node.ts index 39949691c5633..bed304f0ea7d1 100644 --- a/packages/nodes-base/nodes/Google/Contacts/GoogleContacts.node.ts +++ b/packages/nodes-base/nodes/Google/Contacts/GoogleContacts.node.ts @@ -244,7 +244,7 @@ export class GoogleContacts implements INodeType { if (operation === 'get') { const contactId = this.getNodeParameter('contactId', i) as string; const fields = this.getNodeParameter('fields', i) as string[]; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); if (fields.includes('*')) { qs.personFields = allFields.join(','); @@ -263,10 +263,10 @@ export class GoogleContacts implements INodeType { //https://developers.google.com/people/api/rest/v1/people.connections/list //https://developers.google.com/people/api/rest/v1/people/searchContacts if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const fields = this.getNodeParameter('fields', i) as string[]; const options = this.getNodeParameter('options', i, {}) as IDataObject; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); const useQuery = this.getNodeParameter('useQuery', i) as boolean; const endpoint = useQuery ? ':searchContacts' : '/me/connections'; diff --git a/packages/nodes-base/nodes/Google/Drive/GoogleDrive.node.ts b/packages/nodes-base/nodes/Google/Drive/GoogleDrive.node.ts index b099fb0854529..260843ff1966b 100644 --- a/packages/nodes-base/nodes/Google/Drive/GoogleDrive.node.ts +++ b/packages/nodes-base/nodes/Google/Drive/GoogleDrive.node.ts @@ -2198,7 +2198,7 @@ export class GoogleDrive implements INodeType { // ---------------------------------- // list // ---------------------------------- - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const qs: IDataObject = {}; @@ -2509,7 +2509,7 @@ export class GoogleDrive implements INodeType { // ---------------------------------- // upload // ---------------------------------- - const resolveData = this.getNodeParameter('resolveData', 0) as boolean; + const resolveData = this.getNodeParameter('resolveData', 0); let mimeType = 'text/plain'; let body; diff --git a/packages/nodes-base/nodes/Google/Firebase/CloudFirestore/GoogleFirebaseCloudFirestore.node.ts b/packages/nodes-base/nodes/Google/Firebase/CloudFirestore/GoogleFirebaseCloudFirestore.node.ts index c2a23d497dd45..e42b4494d854d 100644 --- a/packages/nodes-base/nodes/Google/Firebase/CloudFirestore/GoogleFirebaseCloudFirestore.node.ts +++ b/packages/nodes-base/nodes/Google/Firebase/CloudFirestore/GoogleFirebaseCloudFirestore.node.ts @@ -181,7 +181,7 @@ export class GoogleFirebaseCloudFirestore implements INodeType { const projectId = this.getNodeParameter('projectId', 0) as string; const database = this.getNodeParameter('database', 0) as string; const collection = this.getNodeParameter('collection', 0) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as string; + const returnAll = this.getNodeParameter('returnAll', 0); const simple = this.getNodeParameter('simple', 0) as boolean; if (returnAll) { @@ -374,7 +374,7 @@ export class GoogleFirebaseCloudFirestore implements INodeType { if (operation === 'getAll') { const projectId = this.getNodeParameter('projectId', 0) as string; const database = this.getNodeParameter('database', 0) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as string; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { const getAllResponse = await googleApiRequestAllItems.call( diff --git a/packages/nodes-base/nodes/Google/GSuiteAdmin/GSuiteAdmin.node.ts b/packages/nodes-base/nodes/Google/GSuiteAdmin/GSuiteAdmin.node.ts index 778216e9b7cc7..6967eb2ef6dd7 100644 --- a/packages/nodes-base/nodes/Google/GSuiteAdmin/GSuiteAdmin.node.ts +++ b/packages/nodes-base/nodes/Google/GSuiteAdmin/GSuiteAdmin.node.ts @@ -160,7 +160,7 @@ export class GSuiteAdmin implements INodeType { //https://developers.google.com/admin-sdk/directory/v1/reference/groups/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; @@ -314,7 +314,7 @@ export class GSuiteAdmin implements INodeType { //https://developers.google.com/admin-sdk/directory/v1/reference/users/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const projection = this.getNodeParameter('projection', i) as string; diff --git a/packages/nodes-base/nodes/Google/Gmail/v1/GmailV1.node.ts b/packages/nodes-base/nodes/Google/Gmail/v1/GmailV1.node.ts index 555b70ada3a91..45f8ccf90525e 100644 --- a/packages/nodes-base/nodes/Google/Gmail/v1/GmailV1.node.ts +++ b/packages/nodes-base/nodes/Google/Gmail/v1/GmailV1.node.ts @@ -242,7 +242,7 @@ export class GmailV1 implements INodeType { responseData = await googleApiRequest.call(this, method, endpoint, body, qs); } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await googleApiRequest.call( this, @@ -516,7 +516,7 @@ export class GmailV1 implements INodeType { responseData = nodeExecutionData; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; Object.assign(qs, additionalFields); @@ -740,7 +740,7 @@ export class GmailV1 implements INodeType { responseData = { success: true }; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; Object.assign(qs, additionalFields); diff --git a/packages/nodes-base/nodes/Google/Gmail/v2/GmailV2.node.ts b/packages/nodes-base/nodes/Google/Gmail/v2/GmailV2.node.ts index 62ec6edd450c3..0d87ea11a75b3 100644 --- a/packages/nodes-base/nodes/Google/Gmail/v2/GmailV2.node.ts +++ b/packages/nodes-base/nodes/Google/Gmail/v2/GmailV2.node.ts @@ -258,7 +258,7 @@ export class GmailV2 implements INodeType { responseData = await googleApiRequest.call(this, 'GET', endpoint); } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await googleApiRequest.call(this, 'GET', `/gmail/v1/users/me/labels`); @@ -379,7 +379,7 @@ export class GmailV2 implements INodeType { responseData = [nodeExecutionData]; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i, {}) as IDataObject; const filters = this.getNodeParameter('filters', i, {}) as IDataObject; const qs: IDataObject = {}; @@ -605,7 +605,7 @@ export class GmailV2 implements INodeType { responseData = { success: true }; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const qs: IDataObject = {}; Object.assign(qs, options); @@ -705,7 +705,7 @@ export class GmailV2 implements INodeType { } if (operation === 'getAll') { //https://developers.google.com/gmail/api/reference/rest/v1/users.threads/list - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; const qs: IDataObject = {}; Object.assign(qs, prepareQuery.call(this, filters)); diff --git a/packages/nodes-base/nodes/Google/Slides/GoogleSlides.node.ts b/packages/nodes-base/nodes/Google/Slides/GoogleSlides.node.ts index 3382b9555835a..a510e25902fd8 100644 --- a/packages/nodes-base/nodes/Google/Slides/GoogleSlides.node.ts +++ b/packages/nodes-base/nodes/Google/Slides/GoogleSlides.node.ts @@ -431,7 +431,7 @@ export class GoogleSlides implements INodeType { `/presentations/${presentationId}/pages/${pageObjectId}/thumbnail`, ); - const download = this.getNodeParameter('download', 0) as boolean; + const download = this.getNodeParameter('download', 0); if (download === true) { const binaryProperty = this.getNodeParameter('binaryProperty', i) as string; @@ -510,7 +510,7 @@ export class GoogleSlides implements INodeType { // ---------------------------------- // presentation: getSlides // ---------------------------------- - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const presentationId = this.getNodeParameter('presentationId', i) as string; responseData = await googleApiRequest.call( this, diff --git a/packages/nodes-base/nodes/Google/Task/GoogleTasks.node.ts b/packages/nodes-base/nodes/Google/Task/GoogleTasks.node.ts index 920514445da41..b485c7cd91e33 100644 --- a/packages/nodes-base/nodes/Google/Task/GoogleTasks.node.ts +++ b/packages/nodes-base/nodes/Google/Task/GoogleTasks.node.ts @@ -157,7 +157,7 @@ export class GoogleTasks implements INodeType { } if (operation === 'getAll') { //https://developers.google.com/tasks/v1/reference/tasks/list - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const taskListId = this.getNodeParameter('task', i) as string; const { showCompleted = true, diff --git a/packages/nodes-base/nodes/Google/YouTube/YouTube.node.ts b/packages/nodes-base/nodes/Google/YouTube/YouTube.node.ts index fd85371001eaa..530ff3518ca7d 100644 --- a/packages/nodes-base/nodes/Google/YouTube/YouTube.node.ts +++ b/packages/nodes-base/nodes/Google/YouTube/YouTube.node.ts @@ -223,7 +223,7 @@ export class YouTube implements INodeType { } //https://developers.google.com/youtube/v3/docs/channels/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); let part = this.getNodeParameter('part', i) as string[]; const options = this.getNodeParameter('options', i) as IDataObject; const filters = this.getNodeParameter('filters', i) as IDataObject; @@ -476,7 +476,7 @@ export class YouTube implements INodeType { } //https://developers.google.com/youtube/v3/docs/playlists/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); let part = this.getNodeParameter('part', i) as string[]; const options = this.getNodeParameter('options', i) as IDataObject; const filters = this.getNodeParameter('filters', i) as IDataObject; @@ -660,7 +660,7 @@ export class YouTube implements INodeType { } //https://developers.google.com/youtube/v3/docs/playlistItems/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); let part = this.getNodeParameter('part', i) as string[]; const options = this.getNodeParameter('options', i) as IDataObject; const playlistId = this.getNodeParameter('playlistId', i) as string; @@ -774,7 +774,7 @@ export class YouTube implements INodeType { if (resource === 'video') { //https://developers.google.com/youtube/v3/docs/search/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const filters = this.getNodeParameter('filters', i) as IDataObject; @@ -1075,7 +1075,7 @@ export class YouTube implements INodeType { if (resource === 'videoCategory') { //https://developers.google.com/youtube/v3/docs/videoCategories/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const regionCode = this.getNodeParameter('regionCode', i) as string; qs.regionCode = regionCode; diff --git a/packages/nodes-base/nodes/Gotify/Gotify.node.ts b/packages/nodes-base/nodes/Gotify/Gotify.node.ts index c213ee45181d8..b67bc48cfbfad 100644 --- a/packages/nodes-base/nodes/Gotify/Gotify.node.ts +++ b/packages/nodes-base/nodes/Gotify/Gotify.node.ts @@ -189,7 +189,7 @@ export class Gotify implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await gotifyApiRequestAllItems.call( @@ -213,10 +213,9 @@ export class Gotify implements INodeType { { itemData: { item: i } }, ); returnData.push(...executionData); - } catch (error) { if (this.continueOnFail()) { - returnData.push({json:{ error: error.message }}); + returnData.push({ json: { error: error.message } }); continue; } throw error; diff --git a/packages/nodes-base/nodes/Grafana/Grafana.node.ts b/packages/nodes-base/nodes/Grafana/Grafana.node.ts index 5fcfec781a75d..ade6d7d3be1a1 100644 --- a/packages/nodes-base/nodes/Grafana/Grafana.node.ts +++ b/packages/nodes-base/nodes/Grafana/Grafana.node.ts @@ -197,7 +197,7 @@ export class Grafana implements INodeType { Object.assign(qs, filters); } - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { const limit = this.getNodeParameter('limit', i) as number; @@ -321,7 +321,7 @@ export class Grafana implements INodeType { responseData = await grafanaApiRequest.call(this, 'GET', '/teams/search', {}, qs); responseData = responseData.teams; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { const limit = this.getNodeParameter('limit', i) as number; @@ -404,7 +404,7 @@ export class Grafana implements INodeType { const endpoint = `/teams/${teamId}/members`; responseData = await grafanaApiRequest.call(this, 'GET', endpoint); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { const limit = this.getNodeParameter('limit', i) as number; @@ -447,7 +447,7 @@ export class Grafana implements INodeType { responseData = await grafanaApiRequest.call(this, 'GET', '/org/users'); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { const limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/Grist/Grist.node.ts b/packages/nodes-base/nodes/Grist/Grist.node.ts index 91f30911d5581..520e18ef1540d 100644 --- a/packages/nodes-base/nodes/Grist/Grist.node.ts +++ b/packages/nodes-base/nodes/Grist/Grist.node.ts @@ -220,7 +220,7 @@ export class Grist implements INodeType { const qs: IDataObject = {}; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { qs.limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/HackerNews/HackerNews.node.ts b/packages/nodes-base/nodes/HackerNews/HackerNews.node.ts index 408171cfff70b..94c72e993c9cb 100644 --- a/packages/nodes-base/nodes/HackerNews/HackerNews.node.ts +++ b/packages/nodes-base/nodes/HackerNews/HackerNews.node.ts @@ -286,7 +286,7 @@ export class HackerNews implements INodeType { tags: tags ? tags.join() : '', }; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { qs.hitsPerPage = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/HaloPSA/HaloPSA.node.ts b/packages/nodes-base/nodes/HaloPSA/HaloPSA.node.ts index 61f57ada4cb29..f80c905a236f6 100644 --- a/packages/nodes-base/nodes/HaloPSA/HaloPSA.node.ts +++ b/packages/nodes-base/nodes/HaloPSA/HaloPSA.node.ts @@ -284,7 +284,7 @@ export class HaloPSA implements INodeType { if (operation === 'getAll') { const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const simplify = this.getNodeParameter('simplify', i) as boolean; const qs: IDataObject = {}; let response; @@ -392,7 +392,7 @@ export class HaloPSA implements INodeType { if (operation === 'getAll') { const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const simplify = this.getNodeParameter('simplify', i) as boolean; const qs: IDataObject = {}; let response; @@ -502,7 +502,7 @@ export class HaloPSA implements INodeType { if (operation === 'getAll') { const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const simplify = this.getNodeParameter('simplify', i) as boolean; const qs: IDataObject = {}; let response; @@ -611,7 +611,7 @@ export class HaloPSA implements INodeType { if (operation === 'getAll') { const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const simplify = this.getNodeParameter('simplify', i) as boolean; const qs: IDataObject = {}; let response; diff --git a/packages/nodes-base/nodes/Harvest/GenericFunctions.ts b/packages/nodes-base/nodes/Harvest/GenericFunctions.ts index 56747a076710c..97a170a3ae0d4 100644 --- a/packages/nodes-base/nodes/Harvest/GenericFunctions.ts +++ b/packages/nodes-base/nodes/Harvest/GenericFunctions.ts @@ -96,7 +96,7 @@ export async function getAllResource( qs.per_page = 100; const additionalFields = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); Object.assign(qs, additionalFields); diff --git a/packages/nodes-base/nodes/HelpScout/HelpScout.node.ts b/packages/nodes-base/nodes/HelpScout/HelpScout.node.ts index efd4182b93ea5..cac556f130453 100644 --- a/packages/nodes-base/nodes/HelpScout/HelpScout.node.ts +++ b/packages/nodes-base/nodes/HelpScout/HelpScout.node.ts @@ -162,7 +162,7 @@ export class HelpScout implements INodeType { const status = this.getNodeParameter('status', i) as string; const subject = this.getNodeParameter('subject', i) as string; const type = this.getNodeParameter('type', i) as string; - const resolveData = this.getNodeParameter('resolveData', i) as boolean; + const resolveData = this.getNodeParameter('resolveData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const threads = (this.getNodeParameter('threadsUi', i) as IDataObject) .threadsValues as IDataObject[]; @@ -246,7 +246,7 @@ export class HelpScout implements INodeType { } //https://developer.helpscout.com/mailbox-api/endpoints/conversations/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; Object.assign(qs, options); if (returnAll) { @@ -275,7 +275,7 @@ export class HelpScout implements INodeType { if (resource === 'customer') { //https://developer.helpscout.com/mailbox-api/endpoints/customers/create if (operation === 'create') { - const resolveData = this.getNodeParameter('resolveData', i) as boolean; + const resolveData = this.getNodeParameter('resolveData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const chats = (this.getNodeParameter('chatsUi', i) as IDataObject) .chatsValues as IDataObject[]; @@ -360,7 +360,7 @@ export class HelpScout implements INodeType { } //https://developer.helpscout.com/mailbox-api/endpoints/customers/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; Object.assign(qs, options); if (returnAll) { @@ -425,7 +425,7 @@ export class HelpScout implements INodeType { } //https://developer.helpscout.com/mailbox-api/endpoints/mailboxes/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await helpscoutApiRequestAllItems.call( this, @@ -534,7 +534,7 @@ export class HelpScout implements INodeType { } //https://developer.helpscout.com/mailbox-api/endpoints/conversations/threads/list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const conversationId = this.getNodeParameter('conversationId', i) as string; if (returnAll) { responseData = await helpscoutApiRequestAllItems.call( diff --git a/packages/nodes-base/nodes/HomeAssistant/HomeAssistant.node.ts b/packages/nodes-base/nodes/HomeAssistant/HomeAssistant.node.ts index b442499801702..91b04a820bdc1 100644 --- a/packages/nodes-base/nodes/HomeAssistant/HomeAssistant.node.ts +++ b/packages/nodes-base/nodes/HomeAssistant/HomeAssistant.node.ts @@ -200,7 +200,7 @@ export class HomeAssistant implements INodeType { } } else if (resource === 'service') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = (await homeAssistantApiRequest.call( this, 'GET', @@ -240,7 +240,7 @@ export class HomeAssistant implements INodeType { } } else if (resource === 'state') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = (await homeAssistantApiRequest.call( this, 'GET', @@ -283,7 +283,7 @@ export class HomeAssistant implements INodeType { } } else if (resource === 'event') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = (await homeAssistantApiRequest.call( this, 'GET', @@ -355,7 +355,7 @@ export class HomeAssistant implements INodeType { } } else if (resource === 'history') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; let endpoint = '/history/period'; diff --git a/packages/nodes-base/nodes/Hubspot/Hubspot.node.ts b/packages/nodes-base/nodes/Hubspot/Hubspot.node.ts index ff5a39fb1eee5..8e2486627ea3c 100644 --- a/packages/nodes-base/nodes/Hubspot/Hubspot.node.ts +++ b/packages/nodes-base/nodes/Hubspot/Hubspot.node.ts @@ -992,7 +992,7 @@ export class Hubspot implements INodeType { //https://developers.hubspot.com/docs/methods/companies/create_company if (operation === 'upsert') { const email = this.getNodeParameter('email', i) as string; - const resolveData = this.getNodeParameter('resolveData', i) as boolean; + const resolveData = this.getNodeParameter('resolveData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const body: IDataObject[] = []; if (additionalFields.annualRevenue) { @@ -1339,7 +1339,7 @@ export class Hubspot implements INodeType { //https://developers.hubspot.com/docs/methods/contacts/get_contacts if (operation === 'getAll') { const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (additionalFields.formSubmissionMode) { qs.formSubmissionMode = additionalFields.formSubmissionMode as string; } @@ -1371,7 +1371,7 @@ export class Hubspot implements INodeType { //https://developers.hubspot.com/docs/methods/contacts/get_recently_created_contacts if (operation === 'getRecentlyCreatedUpdated') { let endpoint; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.formSubmissionMode) { qs.formSubmissionMode = filters.formSubmissionMode as string; @@ -1412,7 +1412,7 @@ export class Hubspot implements INodeType { //https://developers.hubspot.com/docs/api/crm/search if (operation === 'search') { const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const filtersGroupsUi = this.getNodeParameter('filterGroupsUi', i) as IDataObject; const sortBy = additionalFields.sortBy || 'createdate'; const direction = additionalFields.direction || 'DESCENDING'; @@ -1931,7 +1931,7 @@ export class Hubspot implements INodeType { //https://developers.hubspot.com/docs/methods/companies/get-all-companies if (operation === 'getAll') { const options = this.getNodeParameter('options', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (options.includeMergeAudits) { qs.includeMergeAudits = options.includeMergeAudits as boolean; } @@ -1960,7 +1960,7 @@ export class Hubspot implements INodeType { //https://developers.hubspot.com/docs/methods/companies/get_companies_modified if (operation === 'getRecentlyCreated' || operation === 'getRecentlyModified') { let endpoint; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (operation === 'getRecentlyCreated') { endpoint = `/companies/v2/companies/recent/created`; } else { @@ -1989,7 +1989,7 @@ export class Hubspot implements INodeType { if (operation === 'searchByDomain') { const domain = this.getNodeParameter('domain', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const body: IDataObject = { requestOptions: {}, }; @@ -2163,7 +2163,7 @@ export class Hubspot implements INodeType { } if (operation === 'getAll') { const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (filters.includeAssociations) { qs.includeAssociations = filters.includeAssociations as boolean; } @@ -2198,7 +2198,7 @@ export class Hubspot implements INodeType { if (operation === 'getRecentlyCreated' || operation === 'getRecentlyModified') { let endpoint; const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (filters.since) { qs.since = new Date(filters.since as string).getTime(); } @@ -2233,7 +2233,7 @@ export class Hubspot implements INodeType { //https://developers.hubspot.com/docs/api/crm/search if (operation === 'search') { const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const filtersGroupsUi = this.getNodeParameter('filterGroupsUi', i) as IDataObject; const sortBy = additionalFields.sortBy || 'createdate'; const direction = additionalFields.direction || 'DESCENDING'; @@ -2353,7 +2353,7 @@ export class Hubspot implements INodeType { } //https://legacydocs.hubspot.com/docs/methods/engagements/get-all-engagements if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const endpoint = `/engagements/v1/engagements/paged`; if (returnAll) { responseData = await hubspotApiRequestAllItems.call( @@ -2573,7 +2573,7 @@ export class Hubspot implements INodeType { //https://developers.hubspot.com/docs/methods/tickets/get-all-tickets if (operation === 'getAll') { const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (additionalFields.properties) { qs.properties = additionalFields.properties as string[]; } diff --git a/packages/nodes-base/nodes/Hunter/Hunter.node.ts b/packages/nodes-base/nodes/Hunter/Hunter.node.ts index dfa149dddf851..a97ebf16b606d 100644 --- a/packages/nodes-base/nodes/Hunter/Hunter.node.ts +++ b/packages/nodes-base/nodes/Hunter/Hunter.node.ts @@ -277,7 +277,7 @@ export class Hunter implements INodeType { const operation = this.getNodeParameter('operation', 0) as string; //https://hunter.io/api-documentation/v2#domain-search if (operation === 'domainSearch') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; const domain = this.getNodeParameter('domain', i) as string; const onlyEmails = this.getNodeParameter('onlyEmails', i, false) as boolean; diff --git a/packages/nodes-base/nodes/Intercom/Intercom.node.ts b/packages/nodes-base/nodes/Intercom/Intercom.node.ts index eefa1835c49b4..7f09d541acbc3 100644 --- a/packages/nodes-base/nodes/Intercom/Intercom.node.ts +++ b/packages/nodes-base/nodes/Intercom/Intercom.node.ts @@ -114,7 +114,7 @@ export class Intercom implements INodeType { if (resource === 'lead') { if (operation === 'create' || operation === 'update') { const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); const body: ILead = {}; if (operation === 'create') { body.email = this.getNodeParameter('email', i) as string; @@ -229,7 +229,7 @@ export class Intercom implements INodeType { } } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; Object.assign(qs, filters); @@ -271,7 +271,7 @@ export class Intercom implements INodeType { if (resource === 'user') { if (operation === 'create' || operation === 'update') { const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); const body: IUser = {}; if (operation === 'create') { @@ -404,7 +404,7 @@ export class Intercom implements INodeType { } } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; Object.assign(qs, filters); @@ -445,7 +445,7 @@ export class Intercom implements INodeType { if (operation === 'create' || operation === 'update') { const id = this.getNodeParameter('companyId', i) as string; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); const body: ICompany = { company_id: id, }; @@ -528,7 +528,7 @@ export class Intercom implements INodeType { } } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; Object.assign(qs, filters); @@ -558,7 +558,7 @@ export class Intercom implements INodeType { if (operation === 'users') { const listBy = this.getNodeParameter('listBy', 0) as string; const value = this.getNodeParameter('value', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (listBy === 'companyId') { qs.company_id = value; diff --git a/packages/nodes-base/nodes/InvoiceNinja/InvoiceNinja.node.ts b/packages/nodes-base/nodes/InvoiceNinja/InvoiceNinja.node.ts index 5f1301f3d2157..05120426439ae 100644 --- a/packages/nodes-base/nodes/InvoiceNinja/InvoiceNinja.node.ts +++ b/packages/nodes-base/nodes/InvoiceNinja/InvoiceNinja.node.ts @@ -363,7 +363,7 @@ export class InvoiceNinja implements INodeType { responseData = responseData.data; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; if (options.include) { qs.include = options.include as string; @@ -521,7 +521,7 @@ export class InvoiceNinja implements INodeType { responseData = responseData.data; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; if (options.include) { qs.include = options.include as string; @@ -617,7 +617,7 @@ export class InvoiceNinja implements INodeType { responseData = responseData.data; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; if (options.include) { qs.include = options.include as string; @@ -689,7 +689,7 @@ export class InvoiceNinja implements INodeType { responseData = responseData.data; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; if (options.include) { qs.include = options.include as string; @@ -794,7 +794,7 @@ export class InvoiceNinja implements INodeType { responseData = responseData.data; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === true) { responseData = await invoiceNinjaApiRequestAllItems.call( this, @@ -951,7 +951,7 @@ export class InvoiceNinja implements INodeType { responseData = responseData.data; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; if (options.include) { qs.include = options.include as string; diff --git a/packages/nodes-base/nodes/Jenkins/Jenkins.node.ts b/packages/nodes-base/nodes/Jenkins/Jenkins.node.ts index 6a68b27f29248..b7e3cc7f94b79 100644 --- a/packages/nodes-base/nodes/Jenkins/Jenkins.node.ts +++ b/packages/nodes-base/nodes/Jenkins/Jenkins.node.ts @@ -625,7 +625,7 @@ export class Jenkins implements INodeType { if (operation === 'getAll') { const job = this.getNodeParameter('job', i) as string; let endpoint = `/job/${job}/api/json?tree=builds[*]`; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { const limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/Jira/Jira.node.ts b/packages/nodes-base/nodes/Jira/Jira.node.ts index 1dab46e0a13d0..aaa8055c50e5c 100644 --- a/packages/nodes-base/nodes/Jira/Jira.node.ts +++ b/packages/nodes-base/nodes/Jira/Jira.node.ts @@ -734,7 +734,7 @@ export class Jira implements INodeType { //https://developer.atlassian.com/cloud/jira/platform/rest/v2/#api-rest-api-2-search-post if (operation === 'getAll') { for (let i = 0; i < length; i++) { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const body: IDataObject = {}; if (options.fields) { @@ -782,7 +782,7 @@ export class Jira implements INodeType { if (operation === 'changelog') { for (let i = 0; i < length; i++) { const issueKey = this.getNodeParameter('issueKey', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await jiraSoftwareCloudApiRequestAllItems.call( this, @@ -1047,7 +1047,7 @@ export class Jira implements INodeType { } //https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-attachments/#api-rest-api-3-attachment-id-get if (operation === 'get') { - const download = this.getNodeParameter('download', 0) as boolean; + const download = this.getNodeParameter('download', 0); for (let i = 0; i < length; i++) { const attachmentId = this.getNodeParameter('attachmentId', i) as string; responseData = await jiraSoftwareCloudApiRequest.call( @@ -1092,10 +1092,10 @@ export class Jira implements INodeType { } } if (operation === 'getAll') { - const download = this.getNodeParameter('download', 0) as boolean; + const download = this.getNodeParameter('download', 0); for (let i = 0; i < length; i++) { const issueKey = this.getNodeParameter('issueKey', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const { fields: { attachment }, } = await jiraSoftwareCloudApiRequest.call( @@ -1241,7 +1241,7 @@ export class Jira implements INodeType { if (operation === 'getAll') { for (let i = 0; i < length; i++) { const issueKey = this.getNodeParameter('issueKey', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const body: IDataObject = {}; Object.assign(qs, options); diff --git a/packages/nodes-base/nodes/Kafka/Kafka.node.ts b/packages/nodes-base/nodes/Kafka/Kafka.node.ts index 45a6a1ffa7799..197cd53f0cc87 100644 --- a/packages/nodes-base/nodes/Kafka/Kafka.node.ts +++ b/packages/nodes-base/nodes/Kafka/Kafka.node.ts @@ -350,7 +350,7 @@ export class Kafka implements INodeType { const topic = this.getNodeParameter('topic', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const useKey = this.getNodeParameter('useKey', i) as boolean; diff --git a/packages/nodes-base/nodes/Keap/Keap.node.ts b/packages/nodes-base/nodes/Keap/Keap.node.ts index ad47dcac19073..4eeee4e26b54f 100644 --- a/packages/nodes-base/nodes/Keap/Keap.node.ts +++ b/packages/nodes-base/nodes/Keap/Keap.node.ts @@ -281,7 +281,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/Company/listCompaniesUsingGET if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; keysToSnakeCase(options); Object.assign(qs, options); @@ -415,7 +415,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/Contact/listContactsUsingGET if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.email) { qs.email = options.email as boolean; @@ -484,7 +484,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/Note/listNotesUsingGET if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; keysToSnakeCase(filters); Object.assign(qs, filters); @@ -547,7 +547,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/Contact/listAppliedTagsUsingGET if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const contactId = parseInt(this.getNodeParameter('contactId', i) as string, 10); if (returnAll) { responseData = await keapApiRequestAllItems.call( @@ -615,7 +615,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/E-Commerce/listOrdersUsingGET if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; keysToSnakeCase(options); Object.assign(qs, options); @@ -660,7 +660,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/Product/listProductsUsingGET if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; keysToSnakeCase(filters); Object.assign(qs, filters); @@ -702,7 +702,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/Email/listEmailsUsingGET if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; keysToSnakeCase(filters); Object.assign(qs, filters); @@ -787,7 +787,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/File/listFilesUsingGET if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; keysToSnakeCase(filters); Object.assign(qs, filters); @@ -817,7 +817,7 @@ export class Keap implements INodeType { } //https://developer.infusionsoft.com/docs/rest/#!/File/createFileUsingPOST if (operation === 'upload') { - const binaryData = this.getNodeParameter('binaryData', i) as boolean; + const binaryData = this.getNodeParameter('binaryData', i); const fileAssociation = this.getNodeParameter('fileAssociation', i) as string; const isPublic = this.getNodeParameter('isPublic', i) as boolean; const body: IFile = { diff --git a/packages/nodes-base/nodes/Lemlist/Lemlist.node.ts b/packages/nodes-base/nodes/Lemlist/Lemlist.node.ts index 1aad1d4ef9cc9..55cec9ffa3fde 100644 --- a/packages/nodes-base/nodes/Lemlist/Lemlist.node.ts +++ b/packages/nodes-base/nodes/Lemlist/Lemlist.node.ts @@ -123,7 +123,7 @@ export class Lemlist implements INodeType { // https://developer.lemlist.com/#activities - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const qs = {} as IDataObject; const filters = this.getNodeParameter('filters', i); diff --git a/packages/nodes-base/nodes/Linear/Linear.node.ts b/packages/nodes-base/nodes/Linear/Linear.node.ts index 9b89efbac1e0b..79475d07b9924 100644 --- a/packages/nodes-base/nodes/Linear/Linear.node.ts +++ b/packages/nodes-base/nodes/Linear/Linear.node.ts @@ -205,7 +205,7 @@ export class Linear implements INodeType { responseData = responseData.data?.issues?.nodes[0]; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const body: IGraphqlBody = { query: query.getIssues(), variables: { diff --git a/packages/nodes-base/nodes/Magento/Magento2.node.ts b/packages/nodes-base/nodes/Magento/Magento2.node.ts index 231c89088c9db..7323dcd7bda0f 100644 --- a/packages/nodes-base/nodes/Magento/Magento2.node.ts +++ b/packages/nodes-base/nodes/Magento/Magento2.node.ts @@ -407,7 +407,7 @@ export class Magento2 implements INodeType { const sort = this.getNodeParameter('options.sort', i, {}) as { sort: [{ direction: string; field: string }]; }; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); let qs: Search = {}; if (filterType === 'manual') { @@ -588,7 +588,7 @@ export class Magento2 implements INodeType { const sort = this.getNodeParameter('options.sort', i, {}) as { sort: [{ direction: string; field: string }]; }; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); let qs: Search = {}; if (filterType === 'manual') { @@ -710,7 +710,7 @@ export class Magento2 implements INodeType { const sort = this.getNodeParameter('options.sort', i, {}) as { sort: [{ direction: string; field: string }]; }; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); let qs: Search = {}; if (filterType === 'manual') { diff --git a/packages/nodes-base/nodes/Mailchimp/Mailchimp.node.ts b/packages/nodes-base/nodes/Mailchimp/Mailchimp.node.ts index 41041b933194b..a9102bf0dd0ec 100644 --- a/packages/nodes-base/nodes/Mailchimp/Mailchimp.node.ts +++ b/packages/nodes-base/nodes/Mailchimp/Mailchimp.node.ts @@ -1688,7 +1688,7 @@ export class Mailchimp implements INodeType { if (operation === 'getAll') { const listId = this.getNodeParameter('list', i) as string; const categoryId = this.getNodeParameter('groupCategory', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await mailchimpApiRequestAllItems.call( @@ -1719,7 +1719,7 @@ export class Mailchimp implements INodeType { const email = this.getNodeParameter('email', i) as string; const status = this.getNodeParameter('status', i) as Status; const options = this.getNodeParameter('options', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as IDataObject; + const jsonActive = this.getNodeParameter('jsonParameters', i); const body: ICreateMemberBody = { listId, @@ -1850,7 +1850,7 @@ export class Mailchimp implements INodeType { //https://mailchimp.com/developer/reference/lists/list-members/#get_/lists/-list_id-/members if (operation === 'getAll') { const listId = this.getNodeParameter('list', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.beforeLastChanged) { @@ -1904,7 +1904,7 @@ export class Mailchimp implements INodeType { const listId = this.getNodeParameter('list', i) as string; const email = this.getNodeParameter('email', i) as string; const updateFields = this.getNodeParameter('updateFields', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as IDataObject; + const jsonActive = this.getNodeParameter('jsonParameters', i); const body: ICreateMemberBody = { listId, email_address: email, @@ -2071,7 +2071,7 @@ export class Mailchimp implements INodeType { if (resource === 'campaign') { //https://mailchimp.com/developer/api/marketing/campaigns/list-campaigns/ if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.status) { qs.status = options.status as string; diff --git a/packages/nodes-base/nodes/MailerLite/MailerLite.node.ts b/packages/nodes-base/nodes/MailerLite/MailerLite.node.ts index 2c0d73197ffaf..fe60a5efd8f1d 100644 --- a/packages/nodes-base/nodes/MailerLite/MailerLite.node.ts +++ b/packages/nodes-base/nodes/MailerLite/MailerLite.node.ts @@ -126,7 +126,7 @@ export class MailerLite implements INodeType { } //https://developers.mailerlite.com/reference#subscribers if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; diff --git a/packages/nodes-base/nodes/Mailjet/Mailjet.node.ts b/packages/nodes-base/nodes/Mailjet/Mailjet.node.ts index 2135a2a56862c..1186fc58bc93a 100644 --- a/packages/nodes-base/nodes/Mailjet/Mailjet.node.ts +++ b/packages/nodes-base/nodes/Mailjet/Mailjet.node.ts @@ -111,7 +111,7 @@ export class Mailjet implements INodeType { const subject = this.getNodeParameter('subject', i) as string; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const toEmail = (this.getNodeParameter('toEmail', i) as string).split(',') as string[]; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const body: IMessage = { From: { @@ -205,7 +205,7 @@ export class Mailjet implements INodeType { const subject = this.getNodeParameter('subject', i) as string; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const toEmail = (this.getNodeParameter('toEmail', i) as string).split(',') as string[]; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const body: IMessage = { From: { diff --git a/packages/nodes-base/nodes/Mandrill/Mandrill.node.ts b/packages/nodes-base/nodes/Mandrill/Mandrill.node.ts index bf33d153b6747..75ab797ff894d 100644 --- a/packages/nodes-base/nodes/Mandrill/Mandrill.node.ts +++ b/packages/nodes-base/nodes/Mandrill/Mandrill.node.ts @@ -723,7 +723,7 @@ export class Mandrill implements INodeType { const options = this.getNodeParameter('options', i) as Options; const fromEmail = this.getNodeParameter('fromEmail', i) as string; const toEmail = this.getNodeParameter('toEmail', i) as string; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); const toEmailArray = getToEmailArray(toEmail); const message: Message = { diff --git a/packages/nodes-base/nodes/Mautic/Mautic.node.ts b/packages/nodes-base/nodes/Mautic/Mautic.node.ts index 30c207301dabf..83ed5301973b2 100644 --- a/packages/nodes-base/nodes/Mautic/Mautic.node.ts +++ b/packages/nodes-base/nodes/Mautic/Mautic.node.ts @@ -552,7 +552,7 @@ export class Mautic implements INodeType { } //https://developer.mautic.org/#list-contact-companies if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const simple = this.getNodeParameter('simple', i) as boolean; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; qs = Object.assign(qs, additionalFields); @@ -601,7 +601,7 @@ export class Mautic implements INodeType { if (operation === 'create') { const options = this.getNodeParameter('options', i) as IDataObject; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); let body: IDataObject = {}; if (!jsonActive) { body.email = this.getNodeParameter('email', i) as string; @@ -833,7 +833,7 @@ export class Mautic implements INodeType { } //https://developer.mautic.org/?php#list-contacts if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; qs = Object.assign(qs, options); if (qs.orderBy) { @@ -1024,7 +1024,7 @@ export class Mautic implements INodeType { returnData.push(...executionData); } catch (error) { if (this.continueOnFail()) { - returnData.push({ json: { error: (error as JsonObject).message }}); + returnData.push({ json: { error: (error as JsonObject).message } }); continue; } throw error; diff --git a/packages/nodes-base/nodes/Medium/Medium.node.ts b/packages/nodes-base/nodes/Medium/Medium.node.ts index 44ad5ab941ab1..6c2b0177ba81b 100644 --- a/packages/nodes-base/nodes/Medium/Medium.node.ts +++ b/packages/nodes-base/nodes/Medium/Medium.node.ts @@ -493,7 +493,7 @@ export class Medium implements INodeType { // publication:getAll // ---------------------------------- - const returnAll = this.getNodeParameter('returnAll', i) as string; + const returnAll = this.getNodeParameter('returnAll', i); const user = await mediumApiRequest.call(this, 'GET', `/me`); diff --git a/packages/nodes-base/nodes/Microsoft/Dynamics/MicrosoftDynamicsCrm.node.ts b/packages/nodes-base/nodes/Microsoft/Dynamics/MicrosoftDynamicsCrm.node.ts index 925294c3fb5bd..79ebdd89f9950 100644 --- a/packages/nodes-base/nodes/Microsoft/Dynamics/MicrosoftDynamicsCrm.node.ts +++ b/packages/nodes-base/nodes/Microsoft/Dynamics/MicrosoftDynamicsCrm.node.ts @@ -214,7 +214,7 @@ export class MicrosoftDynamicsCrm implements INodeType { if (operation === 'getAll') { //https://docs.microsoft.com/en-us/powerapps/developer/data-platform/webapi/query-data-web-api - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const filters = this.getNodeParameter('filters', i) as IDataObject; if (options.returnFields) { diff --git a/packages/nodes-base/nodes/Microsoft/Excel/MicrosoftExcel.node.ts b/packages/nodes-base/nodes/Microsoft/Excel/MicrosoftExcel.node.ts index 50bacb51fdf70..47cce50030919 100644 --- a/packages/nodes-base/nodes/Microsoft/Excel/MicrosoftExcel.node.ts +++ b/packages/nodes-base/nodes/Microsoft/Excel/MicrosoftExcel.node.ts @@ -260,8 +260,8 @@ export class MicrosoftExcel implements INodeType { const workbookId = this.getNodeParameter('workbook', i) as string; const worksheetId = this.getNodeParameter('worksheet', i) as string; const tableId = this.getNodeParameter('table', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); + const rawData = this.getNodeParameter('rawData', i); if (rawData) { const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.fields) { @@ -322,8 +322,8 @@ export class MicrosoftExcel implements INodeType { const workbookId = this.getNodeParameter('workbook', i) as string; const worksheetId = this.getNodeParameter('worksheet', i) as string; const tableId = this.getNodeParameter('table', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); + const rawData = this.getNodeParameter('rawData', i); if (rawData) { const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.fields) { @@ -519,7 +519,7 @@ export class MicrosoftExcel implements INodeType { ); } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.fields) { qs['$select'] = filters.fields; @@ -580,7 +580,7 @@ export class MicrosoftExcel implements INodeType { try { //https://docs.microsoft.com/en-us/graph/api/workbook-list-worksheets?view=graph-rest-1.0&tabs=http if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const workbookId = this.getNodeParameter('workbook', i) as string; const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.fields) { @@ -612,7 +612,7 @@ export class MicrosoftExcel implements INodeType { const workbookId = this.getNodeParameter('workbook', i) as string; const worksheetId = this.getNodeParameter('worksheet', i) as string; const range = this.getNodeParameter('range', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); if (rawData) { const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.fields) { diff --git a/packages/nodes-base/nodes/Microsoft/GraphSecurity/MicrosoftGraphSecurity.node.ts b/packages/nodes-base/nodes/Microsoft/GraphSecurity/MicrosoftGraphSecurity.node.ts index 7f6f24ad0e392..9ee6ad834ab56 100644 --- a/packages/nodes-base/nodes/Microsoft/GraphSecurity/MicrosoftGraphSecurity.node.ts +++ b/packages/nodes-base/nodes/Microsoft/GraphSecurity/MicrosoftGraphSecurity.node.ts @@ -111,7 +111,7 @@ export class MicrosoftGraphSecurity implements INodeType { qs.$filter = tolerateDoubleQuotes(filter); } - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { qs.$count = true; @@ -161,7 +161,7 @@ export class MicrosoftGraphSecurity implements INodeType { qs.$filter = tolerateDoubleQuotes(filter); } - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { qs.$count = true; diff --git a/packages/nodes-base/nodes/Microsoft/OneDrive/MicrosoftOneDrive.node.ts b/packages/nodes-base/nodes/Microsoft/OneDrive/MicrosoftOneDrive.node.ts index abb93dc8315d3..760b3492276d6 100644 --- a/packages/nodes-base/nodes/Microsoft/OneDrive/MicrosoftOneDrive.node.ts +++ b/packages/nodes-base/nodes/Microsoft/OneDrive/MicrosoftOneDrive.node.ts @@ -195,7 +195,7 @@ export class MicrosoftOneDrive implements INodeType { //https://docs.microsoft.com/en-us/onedrive/developer/rest-api/api/driveitem_put_content?view=odsp-graph-online#example-upload-a-new-file if (operation === 'upload') { const parentId = this.getNodeParameter('parentId', i) as string; - const isBinaryData = this.getNodeParameter('binaryData', i) as boolean; + const isBinaryData = this.getNodeParameter('binaryData', i); const fileName = this.getNodeParameter('fileName', i) as string; if (isBinaryData) { diff --git a/packages/nodes-base/nodes/Microsoft/Outlook/MicrosoftOutlook.node.ts b/packages/nodes-base/nodes/Microsoft/Outlook/MicrosoftOutlook.node.ts index a415689f3996d..67dbb35ef13b2 100644 --- a/packages/nodes-base/nodes/Microsoft/Outlook/MicrosoftOutlook.node.ts +++ b/packages/nodes-base/nodes/Microsoft/Outlook/MicrosoftOutlook.node.ts @@ -478,7 +478,7 @@ export class MicrosoftOutlook implements INodeType { let additionalFields: IDataObject = {}; for (let i = 0; i < length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; if (additionalFields.fields) { @@ -838,7 +838,7 @@ export class MicrosoftOutlook implements INodeType { for (let i = 0; i < length; i++) { try { const messageId = this.getNodeParameter('messageId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; // Have sane defaults so we don't fetch attachment data in this operation @@ -969,7 +969,7 @@ export class MicrosoftOutlook implements INodeType { if (operation === 'getAll') { for (let i = 0; i < length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; if (additionalFields.fields) { @@ -1009,7 +1009,7 @@ export class MicrosoftOutlook implements INodeType { for (let i = 0; i < length; i++) { try { const folderId = this.getNodeParameter('folderId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; if (additionalFields.fields) { @@ -1083,7 +1083,7 @@ export class MicrosoftOutlook implements INodeType { try { if (operation === 'getAll') { const folderId = this.getNodeParameter('folderId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; if (additionalFields.fields) { diff --git a/packages/nodes-base/nodes/Microsoft/Teams/MicrosoftTeams.node.ts b/packages/nodes-base/nodes/Microsoft/Teams/MicrosoftTeams.node.ts index f7166ffbe652b..98d9497ca4fca 100644 --- a/packages/nodes-base/nodes/Microsoft/Teams/MicrosoftTeams.node.ts +++ b/packages/nodes-base/nodes/Microsoft/Teams/MicrosoftTeams.node.ts @@ -313,7 +313,7 @@ export class MicrosoftTeams implements INodeType { //https://docs.microsoft.com/en-us/graph/api/channel-list?view=graph-rest-beta&tabs=http if (operation === 'getAll') { const teamId = this.getNodeParameter('teamId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await microsoftApiRequestAllItems.call( this, @@ -392,7 +392,7 @@ export class MicrosoftTeams implements INodeType { if (operation === 'getAll') { const teamId = this.getNodeParameter('teamId', i) as string; const channelId = this.getNodeParameter('channelId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await microsoftApiRequestAllItems.call( this, @@ -445,7 +445,7 @@ export class MicrosoftTeams implements INodeType { // https://docs.microsoft.com/en-us/graph/api/chat-list-messages?view=graph-rest-1.0&tabs=http if (operation === 'getAll') { const chatId = this.getNodeParameter('chatId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await microsoftApiRequestAllItems.call( this, @@ -533,7 +533,7 @@ export class MicrosoftTeams implements INodeType { } if (operation === 'getAll') { const tasksFor = this.getNodeParameter('tasksFor', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (tasksFor === 'member') { //https://docs.microsoft.com/en-us/graph/api/planneruser-list-tasks?view=graph-rest-1.0&tabs=http const memberId = this.getNodeParameter('memberId', i) as string; diff --git a/packages/nodes-base/nodes/Microsoft/ToDo/MicrosoftToDo.node.ts b/packages/nodes-base/nodes/Microsoft/ToDo/MicrosoftToDo.node.ts index 182a27f44e071..31f69199eac05 100644 --- a/packages/nodes-base/nodes/Microsoft/ToDo/MicrosoftToDo.node.ts +++ b/packages/nodes-base/nodes/Microsoft/ToDo/MicrosoftToDo.node.ts @@ -152,7 +152,7 @@ export class MicrosoftToDo implements INodeType { } else if (operation === 'getAll') { const taskListId = this.getNodeParameter('taskListId', i) as string; const taskId = this.getNodeParameter('taskId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await microsoftApiRequestAllItems.call( @@ -260,7 +260,7 @@ export class MicrosoftToDo implements INodeType { // https://docs.microsoft.com/en-us/graph/api/todotasklist-list-tasks?view=graph-rest-1.0&tabs=http } else if (operation === 'getAll') { const taskListId = this.getNodeParameter('taskListId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await microsoftApiRequestAllItems.call( @@ -353,7 +353,7 @@ export class MicrosoftToDo implements INodeType { // https://docs.microsoft.com/en-us/graph/api/todo-list-lists?view=graph-rest-1.0&tabs=http } else if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await microsoftApiRequestAllItems.call( this, diff --git a/packages/nodes-base/nodes/Mindee/Mindee.node.ts b/packages/nodes-base/nodes/Mindee/Mindee.node.ts index 2c817dc2aba0f..71d92b3ee48e5 100644 --- a/packages/nodes-base/nodes/Mindee/Mindee.node.ts +++ b/packages/nodes-base/nodes/Mindee/Mindee.node.ts @@ -163,7 +163,7 @@ export class Mindee implements INodeType { if (operation === 'predict') { const binaryPropertyName = this.getNodeParameter('binaryPropertyName', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); if (items[i].binary === undefined) { throw new NodeOperationError(this.getNode(), 'No binary data exists on item!', { @@ -234,7 +234,7 @@ export class Mindee implements INodeType { if (operation === 'predict') { const binaryPropertyName = this.getNodeParameter('binaryPropertyName', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); if (items[i].binary === undefined) { throw new NodeOperationError(this.getNode(), 'No binary data exists on item!', { diff --git a/packages/nodes-base/nodes/Misp/GenericFunctions.ts b/packages/nodes-base/nodes/Misp/GenericFunctions.ts index ad7c5c85b0fb3..33a51bbcdac77 100644 --- a/packages/nodes-base/nodes/Misp/GenericFunctions.ts +++ b/packages/nodes-base/nodes/Misp/GenericFunctions.ts @@ -69,7 +69,7 @@ export async function mispApiRequest( export async function mispApiRequestAllItems(this: IExecuteFunctions, endpoint: string) { const responseData = await mispApiRequest.call(this, 'GET', endpoint); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { const limit = this.getNodeParameter('limit', 0) as number; diff --git a/packages/nodes-base/nodes/Misp/Misp.node.ts b/packages/nodes-base/nodes/Misp/Misp.node.ts index 76c9d0ecfd9fe..f919ecd7eda91 100644 --- a/packages/nodes-base/nodes/Misp/Misp.node.ts +++ b/packages/nodes-base/nodes/Misp/Misp.node.ts @@ -600,7 +600,7 @@ export class Misp implements INodeType { responseData = (await mispApiRequest.call(this, 'GET', '/tags')) as LoadedTags; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { const limit = this.getNodeParameter('limit', 0) as number; @@ -717,7 +717,7 @@ export class Misp implements INodeType { Warninglists: Array<{ Warninglist: unknown }>; }; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { const limit = this.getNodeParameter('limit', 0) as number; diff --git a/packages/nodes-base/nodes/MondayCom/MondayCom.node.ts b/packages/nodes-base/nodes/MondayCom/MondayCom.node.ts index fa3f615ec0e53..ba719daa47764 100644 --- a/packages/nodes-base/nodes/MondayCom/MondayCom.node.ts +++ b/packages/nodes-base/nodes/MondayCom/MondayCom.node.ts @@ -302,7 +302,7 @@ export class MondayCom implements INodeType { responseData = responseData.data.boards; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const body: IGraphqlBody = { query: `query ($page: Int, $limit: Int) { @@ -620,7 +620,7 @@ export class MondayCom implements INodeType { if (operation === 'getAll') { const boardId = parseInt(this.getNodeParameter('boardId', i) as string, 10); const groupId = this.getNodeParameter('groupId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const body: IGraphqlBody = { query: `query ($boardId: [Int], $groupId: [String], $page: Int, $limit: Int) { @@ -666,7 +666,7 @@ export class MondayCom implements INodeType { const boardId = parseInt(this.getNodeParameter('boardId', i) as string, 10); const columnId = this.getNodeParameter('columnId', i) as string; const columnValue = this.getNodeParameter('columnValue', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const body: IGraphqlBody = { query: `query ($boardId: Int!, $columnId: String!, $columnValue: String!, $page: Int, $limit: Int ){ diff --git a/packages/nodes-base/nodes/N8nTrainingCustomerDatastore/N8nTrainingCustomerDatastore.node.ts b/packages/nodes-base/nodes/N8nTrainingCustomerDatastore/N8nTrainingCustomerDatastore.node.ts index 1495feaeab568..b64dbcd678214 100644 --- a/packages/nodes-base/nodes/N8nTrainingCustomerDatastore/N8nTrainingCustomerDatastore.node.ts +++ b/packages/nodes-base/nodes/N8nTrainingCustomerDatastore/N8nTrainingCustomerDatastore.node.ts @@ -122,7 +122,7 @@ export class N8nTrainingCustomerDatastore implements INodeType { } if (operation === 'getAllPeople') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = data; diff --git a/packages/nodes-base/nodes/Nasa/Nasa.node.ts b/packages/nodes-base/nodes/Nasa/Nasa.node.ts index 5841b0fcd6968..dd71ebdd4d1e0 100644 --- a/packages/nodes-base/nodes/Nasa/Nasa.node.ts +++ b/packages/nodes-base/nodes/Nasa/Nasa.node.ts @@ -914,7 +914,7 @@ export class Nasa implements INodeType { } if (resource === 'asteroidNeoBrowse') { if (operation === 'getAll') { - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === false) { qs.size = this.getNodeParameter('limit', 0) as number; @@ -1069,7 +1069,7 @@ export class Nasa implements INodeType { } if (resource === 'astronomyPictureOfTheDay') { - download = this.getNodeParameter('download', 0) as boolean; + download = this.getNodeParameter('download', 0); if (download === true) { const binaryProperty = this.getNodeParameter('binaryPropertyName', i) as string; diff --git a/packages/nodes-base/nodes/Netlify/Netlify.node.ts b/packages/nodes-base/nodes/Netlify/Netlify.node.ts index 79ab74817fe66..5ce1d3e6258b2 100644 --- a/packages/nodes-base/nodes/Netlify/Netlify.node.ts +++ b/packages/nodes-base/nodes/Netlify/Netlify.node.ts @@ -135,7 +135,7 @@ export class Netlify implements INodeType { if (operation === 'getAll') { const siteId = this.getNodeParameter('siteId', i); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await netlifyRequestAllItems.call( this, @@ -166,7 +166,7 @@ export class Netlify implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await netlifyRequestAllItems.call( this, diff --git a/packages/nodes-base/nodes/NextCloud/NextCloud.node.ts b/packages/nodes-base/nodes/NextCloud/NextCloud.node.ts index e736f87191bcc..032e5a1dbb98f 100644 --- a/packages/nodes-base/nodes/NextCloud/NextCloud.node.ts +++ b/packages/nodes-base/nodes/NextCloud/NextCloud.node.ts @@ -1056,7 +1056,7 @@ export class NextCloud implements INodeType { // ---------------------------------- requestMethod = 'GET'; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (!returnAll) { qs.limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/NocoDB/NocoDB.node.ts b/packages/nodes-base/nodes/NocoDB/NocoDB.node.ts index 137e3ecdf4e1f..ce105adf38767 100644 --- a/packages/nodes-base/nodes/NocoDB/NocoDB.node.ts +++ b/packages/nodes-base/nodes/NocoDB/NocoDB.node.ts @@ -387,7 +387,7 @@ export class NocoDB implements INodeType { endPoint = `/api/v1/db/data/noco/${projectId}/${table}`; } - returnAll = this.getNodeParameter('returnAll', 0) as boolean; + returnAll = this.getNodeParameter('returnAll', 0); qs = this.getNodeParameter('options', i, {}) as IDataObject; if (qs.sort) { diff --git a/packages/nodes-base/nodes/Notion/v1/NotionV1.node.ts b/packages/nodes-base/nodes/Notion/v1/NotionV1.node.ts index 29ed5cd68acbc..8efa2179a7896 100644 --- a/packages/nodes-base/nodes/Notion/v1/NotionV1.node.ts +++ b/packages/nodes-base/nodes/Notion/v1/NotionV1.node.ts @@ -252,7 +252,7 @@ export class NotionV1 implements INodeType { if (operation === 'getAll') { for (let i = 0; i < length; i++) { const blockId = extractPageId(this.getNodeParameter('blockId', i, '', { extractValue: true }) as string); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await notionApiRequestAllItems.call( this, @@ -301,7 +301,7 @@ export class NotionV1 implements INodeType { const body: IDataObject = { filter: { property: 'object', value: 'database' }, }; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await notionApiRequestAllItems.call( this, @@ -363,7 +363,7 @@ export class NotionV1 implements INodeType { for (let i = 0; i < length; i++) { const simple = this.getNodeParameter('simple', 0) as boolean; const databaseId = this.getNodeParameter('databaseId', i, '', { extractValue: true }) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('options.filter', i, {}) as IDataObject; const sort = this.getNodeParameter('options.sort.sortValue', i, []) as IDataObject[]; const body: IDataObject = { @@ -469,7 +469,7 @@ export class NotionV1 implements INodeType { } if (operation === 'getAll') { for (let i = 0; i < length; i++) { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await notionApiRequestAllItems.call(this, 'results', 'GET', '/users'); } else { @@ -535,7 +535,7 @@ export class NotionV1 implements INodeType { for (let i = 0; i < length; i++) { const text = this.getNodeParameter('text', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const simple = this.getNodeParameter('simple', i) as boolean; const body: IDataObject = {}; diff --git a/packages/nodes-base/nodes/Notion/v2/NotionV2.node.ts b/packages/nodes-base/nodes/Notion/v2/NotionV2.node.ts index 55be1b8837704..62efd3ac0f85a 100644 --- a/packages/nodes-base/nodes/Notion/v2/NotionV2.node.ts +++ b/packages/nodes-base/nodes/Notion/v2/NotionV2.node.ts @@ -259,7 +259,7 @@ export class NotionV2 implements INodeType { if (operation === 'getAll') { for (let i = 0; i < length; i++) { const blockId = extractPageId(this.getNodeParameter('blockId', i, '', { extractValue: true }) as string); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await notionApiRequestAllItems.call( @@ -320,7 +320,7 @@ export class NotionV2 implements INodeType { const body: IDataObject = { filter: { property: 'object', value: 'database' }, }; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await notionApiRequestAllItems.call( this, @@ -350,7 +350,7 @@ export class NotionV2 implements INodeType { for (let i = 0; i < length; i++) { const text = this.getNodeParameter('text', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const simple = this.getNodeParameter('simple', i) as boolean; const body: IDataObject = { filter: { @@ -478,7 +478,7 @@ export class NotionV2 implements INodeType { download = this.getNodeParameter('options.downloadFiles', 0, false) as boolean; const simple = this.getNodeParameter('simple', 0) as boolean; const databaseId = this.getNodeParameter('databaseId', i, '', { extractValue: true }) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filterType = this.getNodeParameter('filterType', 0) as string; const conditions = this.getNodeParameter('filters.conditions', i, []) as IDataObject[]; const sort = this.getNodeParameter('options.sort.sortValue', i, []) as IDataObject[]; @@ -595,7 +595,7 @@ export class NotionV2 implements INodeType { } if (operation === 'getAll') { for (let i = 0; i < length; i++) { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await notionApiRequestAllItems.call(this, 'results', 'GET', '/users'); } else { @@ -663,7 +663,7 @@ export class NotionV2 implements INodeType { for (let i = 0; i < length; i++) { const text = this.getNodeParameter('text', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const simple = this.getNodeParameter('simple', i) as boolean; const body: IDataObject = {}; diff --git a/packages/nodes-base/nodes/Odoo/Odoo.node.ts b/packages/nodes-base/nodes/Odoo/Odoo.node.ts index 90ec72daf06fb..8d5fab7ebbdcf 100644 --- a/packages/nodes-base/nodes/Odoo/Odoo.node.ts +++ b/packages/nodes-base/nodes/Odoo/Odoo.node.ts @@ -381,7 +381,7 @@ export class Odoo implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const fields = (options.fieldsList as IDataObject[]) || []; if (returnAll) { @@ -490,7 +490,7 @@ export class Odoo implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const fields = (options.fieldsList as IDataObject[]) || []; const filter = this.getNodeParameter('filterRequest', i) as IOdooFilterOperations; @@ -592,7 +592,7 @@ export class Odoo implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const fields = (options.fieldsList as IDataObject[]) || []; if (returnAll) { @@ -697,7 +697,7 @@ export class Odoo implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; const fields = (options.fieldsList as IDataObject[]) || []; if (returnAll) { diff --git a/packages/nodes-base/nodes/OneSimpleApi/OneSimpleApi.node.ts b/packages/nodes-base/nodes/OneSimpleApi/OneSimpleApi.node.ts index ba0bafa8486b7..6a6c7d76d967e 100644 --- a/packages/nodes-base/nodes/OneSimpleApi/OneSimpleApi.node.ts +++ b/packages/nodes-base/nodes/OneSimpleApi/OneSimpleApi.node.ts @@ -664,7 +664,7 @@ export class OneSimpleApi implements INodeType { if (operation === 'pdf') { const link = this.getNodeParameter('link', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; - download = this.getNodeParameter('download', i) as boolean; + download = this.getNodeParameter('download', i); qs.url = link; if (options.page) { @@ -704,7 +704,7 @@ export class OneSimpleApi implements INodeType { if (operation === 'screenshot') { const link = this.getNodeParameter('link', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; - download = this.getNodeParameter('download', i) as boolean; + download = this.getNodeParameter('download', i); qs.url = link; @@ -817,7 +817,7 @@ export class OneSimpleApi implements INodeType { if (operation === 'qrCode') { const message = this.getNodeParameter('message', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; - download = this.getNodeParameter('download', i) as boolean; + download = this.getNodeParameter('download', i); qs.message = message; diff --git a/packages/nodes-base/nodes/Orbit/Orbit.node.ts b/packages/nodes-base/nodes/Orbit/Orbit.node.ts index e2aeef30087ac..5dd9e6e63af02 100644 --- a/packages/nodes-base/nodes/Orbit/Orbit.node.ts +++ b/packages/nodes-base/nodes/Orbit/Orbit.node.ts @@ -157,7 +157,7 @@ export class Orbit implements INodeType { } if (operation === 'getAll') { const workspaceId = this.getNodeParameter('workspaceId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; let endpoint = `/${workspaceId}/activities`; if (filters.memberId) { @@ -287,7 +287,7 @@ export class Orbit implements INodeType { } if (operation === 'getAll') { const workspaceId = this.getNodeParameter('workspaceId', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', i) as IDataObject; Object.assign(qs, options); qs.resolveIdentities = this.getNodeParameter('resolveIdentities', 0) as boolean; @@ -416,7 +416,7 @@ export class Orbit implements INodeType { if (operation === 'getAll') { const workspaceId = this.getNodeParameter('workspaceId', i) as string; const memberId = this.getNodeParameter('memberId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs.resolveMember = this.getNodeParameter('resolveMember', 0) as boolean; if (returnAll === true) { responseData = await orbitApiRequestAllItems.call( @@ -481,7 +481,7 @@ export class Orbit implements INodeType { } if (operation === 'getAll') { const workspaceId = this.getNodeParameter('workspaceId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; let endpoint = `/${workspaceId}/activities`; qs.type = 'content'; diff --git a/packages/nodes-base/nodes/Oura/Oura.node.ts b/packages/nodes-base/nodes/Oura/Oura.node.ts index 343f1acf37c67..bc34c1f939c29 100644 --- a/packages/nodes-base/nodes/Oura/Oura.node.ts +++ b/packages/nodes-base/nodes/Oura/Oura.node.ts @@ -93,7 +93,7 @@ export class Oura implements INodeType { end: string; }; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (start) { qs.start = moment(start).format('YYYY-MM-DD'); diff --git a/packages/nodes-base/nodes/Paddle/Paddle.node.ts b/packages/nodes-base/nodes/Paddle/Paddle.node.ts index 2366e31fa32c8..e2e4c53b5be3f 100644 --- a/packages/nodes-base/nodes/Paddle/Paddle.node.ts +++ b/packages/nodes-base/nodes/Paddle/Paddle.node.ts @@ -175,7 +175,7 @@ export class Paddle implements INodeType { try { if (resource === 'coupon') { if (operation === 'create') { - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const additionalFieldsJson = this.getNodeParameter( @@ -253,7 +253,7 @@ export class Paddle implements INodeType { if (operation === 'getAll') { const productId = this.getNodeParameter('productId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const endpoint = '/2.0/product/list_coupons'; body.product_id = productId as string; @@ -269,7 +269,7 @@ export class Paddle implements INodeType { } if (operation === 'update') { - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const additionalFieldsJson = this.getNodeParameter( @@ -351,8 +351,8 @@ export class Paddle implements INodeType { } if (resource === 'payment') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const additionalFieldsJson = this.getNodeParameter( @@ -423,7 +423,7 @@ export class Paddle implements INodeType { } if (resource === 'plan') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const endpoint = '/2.0/subscription/plans'; responseData = await paddleApiRequest.call(this, endpoint, 'POST', body); @@ -448,7 +448,7 @@ export class Paddle implements INodeType { } if (resource === 'product') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const endpoint = '/2.0/product/get_products'; responseData = await paddleApiRequest.call(this, endpoint, 'POST', body); @@ -473,9 +473,9 @@ export class Paddle implements INodeType { } if (resource === 'user') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const additionalFieldsJson = this.getNodeParameter( diff --git a/packages/nodes-base/nodes/PagerDuty/PagerDuty.node.ts b/packages/nodes-base/nodes/PagerDuty/PagerDuty.node.ts index 1cee3902a36d9..22d192dd96255 100644 --- a/packages/nodes-base/nodes/PagerDuty/PagerDuty.node.ts +++ b/packages/nodes-base/nodes/PagerDuty/PagerDuty.node.ts @@ -277,7 +277,7 @@ export class PagerDuty implements INodeType { } //https://api-reference.pagerduty.com/#!/Incidents/get_incidents if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', 0) as IDataObject; if (options.userIds) { options.userIds = (options.userIds as string).split(',') as string[]; @@ -390,7 +390,7 @@ export class PagerDuty implements INodeType { //https://api-reference.pagerduty.com/#!/Incidents/get_incidents_id_notes if (operation === 'getAll') { const incidentId = this.getNodeParameter('incidentId', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { responseData = await pagerDutyApiRequestAllItems.call( this, @@ -429,7 +429,7 @@ export class PagerDuty implements INodeType { const options = this.getNodeParameter('options', i) as IDataObject; Object.assign(qs, options); keysToSnakeCase(qs); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { responseData = await pagerDutyApiRequestAllItems.call( this, diff --git a/packages/nodes-base/nodes/PayPal/PayPal.node.ts b/packages/nodes-base/nodes/PayPal/PayPal.node.ts index 35894ecabd78f..35c8241d8723d 100644 --- a/packages/nodes-base/nodes/PayPal/PayPal.node.ts +++ b/packages/nodes-base/nodes/PayPal/PayPal.node.ts @@ -144,7 +144,7 @@ export class PayPal implements INodeType { if (operation === 'create') { const body: IPaymentBatch = {}; const header: ISenderBatchHeader = {}; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); const senderBatchId = this.getNodeParameter('senderBatchId', i) as string; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; header.sender_batch_id = senderBatchId; @@ -190,7 +190,7 @@ export class PayPal implements INodeType { } if (operation === 'get') { const payoutBatchId = this.getNodeParameter('payoutBatchId', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === true) { responseData = await payPalApiRequestAllItems.call( this, diff --git a/packages/nodes-base/nodes/Phantombuster/Phantombuster.node.ts b/packages/nodes-base/nodes/Phantombuster/Phantombuster.node.ts index a5e865476da67..4aaa6e19f93c8 100644 --- a/packages/nodes-base/nodes/Phantombuster/Phantombuster.node.ts +++ b/packages/nodes-base/nodes/Phantombuster/Phantombuster.node.ts @@ -137,7 +137,7 @@ export class Phantombuster implements INodeType { if (operation === 'getOutput') { const agentId = this.getNodeParameter('agentId', i) as string; - const resolveData = this.getNodeParameter('resolveData', i) as boolean; + const resolveData = this.getNodeParameter('resolveData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; @@ -171,7 +171,7 @@ export class Phantombuster implements INodeType { } //https://api.phantombuster.com/api/v2/agents/fetch-all if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await phantombusterApiRequest.call(this, 'GET', '/agents/fetch-all'); @@ -184,9 +184,9 @@ export class Phantombuster implements INodeType { if (operation === 'launch') { const agentId = this.getNodeParameter('agentId', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); - const resolveData = this.getNodeParameter('resolveData', i) as boolean; + const resolveData = this.getNodeParameter('resolveData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; diff --git a/packages/nodes-base/nodes/PhilipsHue/PhilipsHue.node.ts b/packages/nodes-base/nodes/PhilipsHue/PhilipsHue.node.ts index 1861c08d5cc5d..bc118d22f3a41 100644 --- a/packages/nodes-base/nodes/PhilipsHue/PhilipsHue.node.ts +++ b/packages/nodes-base/nodes/PhilipsHue/PhilipsHue.node.ts @@ -151,7 +151,7 @@ export class PhilipsHue implements INodeType { ); } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const user = await getUser.call(this); diff --git a/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts b/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts index 201ba04f62e25..89c577a4068e7 100644 --- a/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts +++ b/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts @@ -4105,7 +4105,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4193,7 +4193,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4225,7 +4225,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; qs.term = this.getNodeParameter('term', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); qs.exact_match = this.getNodeParameter('exactMatch', i) as boolean; if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; @@ -4263,7 +4263,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; const dealId = this.getNodeParameter('dealId', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; @@ -4436,7 +4436,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; endpoint = `/notes`; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4535,7 +4535,7 @@ export class Pipedrive implements INodeType { // https://developers.pipedrive.com/docs/api/v1/Leads#getLeads - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4626,7 +4626,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4667,7 +4667,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; qs.term = this.getNodeParameter('term', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4723,7 +4723,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4747,7 +4747,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; qs.term = this.getNodeParameter('term', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4796,7 +4796,7 @@ export class Pipedrive implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -4876,7 +4876,7 @@ export class Pipedrive implements INodeType { responseData = responseData.data; if (responseData.data === true) { - responseData = {success: true}; + responseData = { success: true }; } const executionData = this.helpers.constructExecutionMetaData( @@ -4890,7 +4890,7 @@ export class Pipedrive implements INodeType { if (resource === 'file' && operation === 'download') { items[i].json = { error: error.message }; } else { - returnData.push({json:{ error: error.message }}); + returnData.push({ json: { error: error.message } }); } continue; } diff --git a/packages/nodes-base/nodes/Pushbullet/Pushbullet.node.ts b/packages/nodes-base/nodes/Pushbullet/Pushbullet.node.ts index 7835025bd2fb1..2de287c9c4d4d 100644 --- a/packages/nodes-base/nodes/Pushbullet/Pushbullet.node.ts +++ b/packages/nodes-base/nodes/Pushbullet/Pushbullet.node.ts @@ -457,7 +457,7 @@ export class Pushbullet implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const filters = this.getNodeParameter('filters', i) as IDataObject; diff --git a/packages/nodes-base/nodes/QuickBase/QuickBase.node.ts b/packages/nodes-base/nodes/QuickBase/QuickBase.node.ts index f77aeedf20aa4..663d8cbb9de8d 100644 --- a/packages/nodes-base/nodes/QuickBase/QuickBase.node.ts +++ b/packages/nodes-base/nodes/QuickBase/QuickBase.node.ts @@ -127,7 +127,7 @@ export class QuickBase implements INodeType { if (resource === 'field') { if (operation === 'getAll') { for (let i = 0; i < length; i++) { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const tableId = this.getNodeParameter('tableId', i) as string; @@ -325,7 +325,7 @@ export class QuickBase implements INodeType { if (operation === 'getAll') { for (let i = 0; i < length; i++) { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const tableId = this.getNodeParameter('tableId', i) as string; @@ -558,7 +558,7 @@ export class QuickBase implements INodeType { if (resource === 'report') { if (operation === 'run') { for (let i = 0; i < length; i++) { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const tableId = this.getNodeParameter('tableId', i) as string; diff --git a/packages/nodes-base/nodes/QuickBooks/QuickBooks.node.ts b/packages/nodes-base/nodes/QuickBooks/QuickBooks.node.ts index ccd20489a0b4b..03bf9f4e0199c 100644 --- a/packages/nodes-base/nodes/QuickBooks/QuickBooks.node.ts +++ b/packages/nodes-base/nodes/QuickBooks/QuickBooks.node.ts @@ -562,7 +562,7 @@ export class QuickBooks implements INodeType { // ---------------------------------- const estimateId = this.getNodeParameter('estimateId', i) as string; - const download = this.getNodeParameter('download', i) as boolean; + const download = this.getNodeParameter('download', i); if (download) { responseData = await handleBinaryData.call( @@ -723,7 +723,7 @@ export class QuickBooks implements INodeType { // ---------------------------------- const invoiceId = this.getNodeParameter('invoiceId', i) as string; - const download = this.getNodeParameter('download', i) as boolean; + const download = this.getNodeParameter('download', i); if (download) { responseData = await handleBinaryData.call( @@ -886,7 +886,7 @@ export class QuickBooks implements INodeType { // ---------------------------------- const paymentId = this.getNodeParameter('paymentId', i) as string; - const download = this.getNodeParameter('download', i) as boolean; + const download = this.getNodeParameter('download', i); if (download) { responseData = await handleBinaryData.call( @@ -1123,7 +1123,7 @@ export class QuickBooks implements INodeType { } } catch (error) { if (this.continueOnFail()) { - const download = this.getNodeParameter('download', 0, false) as boolean; + const download = this.getNodeParameter('download', 0, false); if ( ['invoice', 'estimate', 'payment'].includes(resource) && ['get'].includes(operation) && @@ -1155,7 +1155,7 @@ export class QuickBooks implements INodeType { returnData.push(...executionData); } - const download = this.getNodeParameter('download', 0, false) as boolean; + const download = this.getNodeParameter('download', 0, false); if ( ['invoice', 'estimate', 'payment'].includes(resource) && diff --git a/packages/nodes-base/nodes/Raindrop/Raindrop.node.ts b/packages/nodes-base/nodes/Raindrop/Raindrop.node.ts index 60ff1c3879fb3..4e2d55aed5891 100644 --- a/packages/nodes-base/nodes/Raindrop/Raindrop.node.ts +++ b/packages/nodes-base/nodes/Raindrop/Raindrop.node.ts @@ -165,7 +165,7 @@ export class Raindrop implements INodeType { // ---------------------------------- // bookmark: getAll // ---------------------------------- - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const collectionId = this.getNodeParameter('collectionId', i); const endpoint = `/raindrops/${collectionId}`; @@ -272,7 +272,7 @@ export class Raindrop implements INodeType { // collection: getAll // ---------------------------------- - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const endpoint = this.getNodeParameter('type', i) === 'parent' @@ -415,7 +415,7 @@ export class Raindrop implements INodeType { let endpoint = `/tags`; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filter = this.getNodeParameter('filters', i) as IDataObject; diff --git a/packages/nodes-base/nodes/Reddit/Reddit.node.ts b/packages/nodes-base/nodes/Reddit/Reddit.node.ts index 3f21c4170c0ef..9708eb9f46ac9 100644 --- a/packages/nodes-base/nodes/Reddit/Reddit.node.ts +++ b/packages/nodes-base/nodes/Reddit/Reddit.node.ts @@ -205,7 +205,7 @@ export class Reddit implements INodeType { responseData = await handleListing.call(this, i, endpoint, qs); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (!returnAll) { const limit = this.getNodeParameter('limit', 0) as number; @@ -368,7 +368,7 @@ export class Reddit implements INodeType { const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.trending) { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const endpoint = 'api/trending_subreddits.json'; responseData = await redditApiRequest.call(this, 'GET', endpoint, {}); responseData = responseData.subreddit_names.map((name: string) => ({ name })); @@ -383,7 +383,7 @@ export class Reddit implements INodeType { const endpoint = 'api/search_subreddits.json'; responseData = await redditApiRequest.call(this, 'POST', endpoint, qs); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll === false) { const limit = this.getNodeParameter('limit', 0) as number; diff --git a/packages/nodes-base/nodes/Rocketchat/Rocketchat.node.ts b/packages/nodes-base/nodes/Rocketchat/Rocketchat.node.ts index 87c55d6b0f28d..c51b37a9cf85a 100644 --- a/packages/nodes-base/nodes/Rocketchat/Rocketchat.node.ts +++ b/packages/nodes-base/nodes/Rocketchat/Rocketchat.node.ts @@ -378,7 +378,7 @@ export class Rocketchat implements INodeType { const channel = this.getNodeParameter('channel', i) as string; const text = this.getNodeParameter('text', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); const body: IPostMessageBody = { channel, diff --git a/packages/nodes-base/nodes/S3/S3.node.ts b/packages/nodes-base/nodes/S3/S3.node.ts index 5f51f20566e66..4997726e033c1 100644 --- a/packages/nodes-base/nodes/S3/S3.node.ts +++ b/packages/nodes-base/nodes/S3/S3.node.ts @@ -164,7 +164,7 @@ export class S3 implements INodeType { } //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBuckets.html if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { responseData = await s3ApiRequestSOAPAllItems.call( this, @@ -192,7 +192,7 @@ export class S3 implements INodeType { //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html if (operation === 'search') { const bucketName = this.getNodeParameter('bucketName', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const additionalFields = this.getNodeParameter('additionalFields', 0) as IDataObject; if (additionalFields.prefix) { @@ -389,7 +389,7 @@ export class S3 implements INodeType { //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html if (operation === 'getAll') { const bucketName = this.getNodeParameter('bucketName', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', 0) as IDataObject; if (options.folderKey) { @@ -669,7 +669,7 @@ export class S3 implements INodeType { //https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html if (operation === 'getAll') { const bucketName = this.getNodeParameter('bucketName', i) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const options = this.getNodeParameter('options', 0) as IDataObject; if (options.folderKey) { diff --git a/packages/nodes-base/nodes/Salesforce/Salesforce.node.ts b/packages/nodes-base/nodes/Salesforce/Salesforce.node.ts index 3e52d174b5223..5ddcc63735950 100644 --- a/packages/nodes-base/nodes/Salesforce/Salesforce.node.ts +++ b/packages/nodes-base/nodes/Salesforce/Salesforce.node.ts @@ -1287,7 +1287,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_query.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -1633,7 +1633,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_query.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -1789,7 +1789,7 @@ export class Salesforce implements INodeType { } if (operation === 'getAll') { const customObject = this.getNodeParameter('customObject', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -2034,7 +2034,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_query.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -2324,7 +2324,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_query.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -2539,7 +2539,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_query.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -2802,7 +2802,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_query.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -2934,7 +2934,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_query.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -2989,7 +2989,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_query.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; try { if (returnAll) { @@ -3023,7 +3023,7 @@ export class Salesforce implements INodeType { //https://developer.salesforce.com/docs/atlas.en-us.api_action.meta/api_action/actions_obj_flow.htm if (operation === 'invoke') { const apiName = this.getNodeParameter('apiName', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); let variables = {}; if (jsonParameters) { variables = this.getNodeParameter('variablesJson', i) as object; @@ -3050,7 +3050,7 @@ export class Salesforce implements INodeType { } //https://developer.salesforce.com/docs/atlas.en-us.api_action.meta/api_action/actions_obj_flow.htm if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await salesforceApiRequest.call(this, 'GET', '/actions/custom/flow'); responseData = responseData.actions; if (returnAll === false) { diff --git a/packages/nodes-base/nodes/Salesmate/Salesmate.node.ts b/packages/nodes-base/nodes/Salesmate/Salesmate.node.ts index 2a4c7bfa48494..321f1e63c60e3 100644 --- a/packages/nodes-base/nodes/Salesmate/Salesmate.node.ts +++ b/packages/nodes-base/nodes/Salesmate/Salesmate.node.ts @@ -144,7 +144,7 @@ export class Salesmate implements INodeType { if (operation === 'create') { const owner = this.getNodeParameter('owner', i) as number; const name = this.getNodeParameter('name', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const body: ICompany = { name, @@ -207,7 +207,7 @@ export class Salesmate implements INodeType { if (operation === 'update') { const companyId = this.getNodeParameter('id', i) as string; const updateFields = this.getNodeParameter('updateFields', i) as IDataObject; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); const body: ICompany = {}; if (updateFields.owner) { body.owner = updateFields.owner as number; @@ -276,7 +276,7 @@ export class Salesmate implements INodeType { } if (operation === 'get') { const companyId = this.getNodeParameter('id', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); responseData = await salesmateApiRequest.call(this, 'GET', `/v1/companies/${companyId}`); responseData = responseData.Data; @@ -285,9 +285,9 @@ export class Salesmate implements INodeType { } } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); let body: IDataObject = { query: { group: {}, @@ -389,7 +389,7 @@ export class Salesmate implements INodeType { const owner = this.getNodeParameter('owner', i) as number; const title = this.getNodeParameter('title', i) as string; const type = this.getNodeParameter('type', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const body: IActivity = { title, @@ -422,7 +422,7 @@ export class Salesmate implements INodeType { } if (operation === 'update') { const activityId = this.getNodeParameter('id', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); const updateFields = this.getNodeParameter('updateFields', i) as IDataObject; const body: IActivity = {}; if (updateFields.title) { @@ -465,7 +465,7 @@ export class Salesmate implements INodeType { } if (operation === 'get') { const activityId = this.getNodeParameter('id', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); responseData = await salesmateApiRequest.call( this, 'GET', @@ -478,9 +478,9 @@ export class Salesmate implements INodeType { } } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); let body: IDataObject = { query: { group: {}, @@ -587,7 +587,7 @@ export class Salesmate implements INodeType { const status = this.getNodeParameter('status', i) as string; const stage = this.getNodeParameter('stage', i) as string; const currency = this.getNodeParameter('currency', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const body: IDeal = { title, @@ -627,7 +627,7 @@ export class Salesmate implements INodeType { } if (operation === 'update') { const dealId = this.getNodeParameter('id', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); const updateFields = this.getNodeParameter('updateFields', i) as IDataObject; const body: IDeal = {}; if (updateFields.title) { @@ -680,7 +680,7 @@ export class Salesmate implements INodeType { } if (operation === 'get') { const dealId = this.getNodeParameter('id', i) as string; - const rawData = this.getNodeParameter('rawData', i) as boolean; + const rawData = this.getNodeParameter('rawData', i); responseData = await salesmateApiRequest.call(this, 'GET', `/v1/deals/${dealId}`); responseData = responseData.Data; @@ -689,9 +689,9 @@ export class Salesmate implements INodeType { } } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); let body: IDataObject = { query: { group: {}, diff --git a/packages/nodes-base/nodes/SeaTable/SeaTable.node.ts b/packages/nodes-base/nodes/SeaTable/SeaTable.node.ts index 9912a1fda81aa..6e490433172f8 100644 --- a/packages/nodes-base/nodes/SeaTable/SeaTable.node.ts +++ b/packages/nodes-base/nodes/SeaTable/SeaTable.node.ts @@ -290,7 +290,7 @@ export class SeaTable implements INodeType { qs.table_name = tableName; const filters = this.getNodeParameter('filters', i) as IDataObject; const options = this.getNodeParameter('options', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); Object.assign(qs, filters, options); diff --git a/packages/nodes-base/nodes/SecurityScorecard/SecurityScorecard.node.ts b/packages/nodes-base/nodes/SecurityScorecard/SecurityScorecard.node.ts index 146fc0edc03a4..686b918e3d21d 100644 --- a/packages/nodes-base/nodes/SecurityScorecard/SecurityScorecard.node.ts +++ b/packages/nodes-base/nodes/SecurityScorecard/SecurityScorecard.node.ts @@ -155,7 +155,7 @@ export class SecurityScorecard implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); responseData = await scorecardApiRequest.call(this, 'GET', 'portfolios'); responseData = responseData.entries; @@ -192,7 +192,7 @@ export class SecurityScorecard implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const portfolioId = this.getNodeParameter('portfolioId', i) as string; const filterParams = this.getNodeParameter('filters', i) as IDataObject; responseData = await scorecardApiRequest.call( @@ -292,7 +292,7 @@ export class SecurityScorecard implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); responseData = await scorecardApiRequest.call(this, 'GET', 'reports/recent'); responseData = responseData.entries; @@ -333,7 +333,7 @@ export class SecurityScorecard implements INodeType { if (operation === 'getFactor') { const simple = this.getNodeParameter('simple', 0) as boolean; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const industry = this.getNodeParameter('industry', i); responseData = await scorecardApiRequest.call( this, @@ -356,7 +356,7 @@ export class SecurityScorecard implements INodeType { if (operation === 'getFactorHistorical') { const simple = this.getNodeParameter('simple', 0) as boolean; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const industry = this.getNodeParameter('industry', i); const options = this.getNodeParameter('options', i) as IDataObject; // Convert to YYYY-MM-DD @@ -401,7 +401,7 @@ export class SecurityScorecard implements INodeType { } if (operation === 'getFactor') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const scorecardIdentifier = this.getNodeParameter('scorecardIdentifier', i); const filterParams = this.getNodeParameter('filters', i) as IDataObject; responseData = await scorecardApiRequest.call( @@ -424,7 +424,7 @@ export class SecurityScorecard implements INodeType { if (operation === 'getFactorHistorical') { const simple = this.getNodeParameter('simple', 0) as boolean; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const scorecardIdentifier = this.getNodeParameter('scorecardIdentifier', i) as string; const options = this.getNodeParameter('options', i) as IDataObject; // Convert to YYYY-MM-DD @@ -459,7 +459,7 @@ export class SecurityScorecard implements INodeType { if (operation === 'getHistoricalScore') { const simple = this.getNodeParameter('simple', 0) as boolean; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const scorecardIdentifier = this.getNodeParameter('scorecardIdentifier', i); const options = this.getNodeParameter('options', i) as IDataObject; @@ -494,7 +494,7 @@ export class SecurityScorecard implements INodeType { } if (operation === 'getScorePlan') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const scorecardIdentifier = this.getNodeParameter('scorecardIdentifier', i) as string; const targetScore = this.getNodeParameter('score', i); responseData = await scorecardApiRequest.call( diff --git a/packages/nodes-base/nodes/SendGrid/SendGrid.node.ts b/packages/nodes-base/nodes/SendGrid/SendGrid.node.ts index a58fbf3882fe8..038fac10a6c38 100644 --- a/packages/nodes-base/nodes/SendGrid/SendGrid.node.ts +++ b/packages/nodes-base/nodes/SendGrid/SendGrid.node.ts @@ -145,7 +145,7 @@ export class SendGrid implements INodeType { if (operation === 'getAll') { for (let i = 0; i < length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; let endpoint = '/marketing/contacts'; let method = 'GET'; @@ -169,14 +169,14 @@ export class SendGrid implements INodeType { } const executionData = this.helpers.constructExecutionMetaData( this.helpers.returnJsonArray(responseData), - { itemData: {item: i} }, + { itemData: { item: i } }, ); returnData.push(...executionData); } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({error: error.message}), - { itemData: {item: i} }, + this.helpers.returnJsonArray({ error: error.message }), + { itemData: { item: i } }, ); returnData.push(...executionData); continue; @@ -210,14 +210,14 @@ export class SendGrid implements INodeType { const executionData = this.helpers.constructExecutionMetaData( this.helpers.returnJsonArray(responseData), - { itemData: {item: i} }, + { itemData: { item: i } }, ); returnData.push(...executionData); } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({error: error.message}), - { itemData: {item: i} }, + this.helpers.returnJsonArray({ error: error.message }), + { itemData: { item: i } }, ); returnData.push(...executionData); continue; @@ -307,7 +307,7 @@ export class SendGrid implements INodeType { returnData.push(responseData); } catch (error) { if (this.continueOnFail()) { - returnData.push({ json:{ error: error.message } }); + returnData.push({ json: { error: error.message } }); } else { throw error; } @@ -331,14 +331,14 @@ export class SendGrid implements INodeType { const executionData = this.helpers.constructExecutionMetaData( this.helpers.returnJsonArray(responseData), - { itemData: {item: i} }, + { itemData: { item: i } }, ); returnData.push(...executionData); } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({error: error.message}), - { itemData: {item: i} }, + this.helpers.returnJsonArray({ error: error.message }), + { itemData: { item: i } }, ); returnData.push(...executionData); continue; @@ -352,7 +352,7 @@ export class SendGrid implements INodeType { if (operation === 'getAll') { for (let i = 0; i < length; i++) { try { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await sendGridApiRequestAllItems.call( this, `/marketing/lists`, @@ -374,8 +374,8 @@ export class SendGrid implements INodeType { } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({error: error.message}), - { itemData: {item: i} }, + this.helpers.returnJsonArray({ error: error.message }), + { itemData: { item: i } }, ); returnData.push(...executionData); continue; @@ -399,14 +399,14 @@ export class SendGrid implements INodeType { const executionData = this.helpers.constructExecutionMetaData( this.helpers.returnJsonArray(responseData), - { itemData: {item: i} }, + { itemData: { item: i } }, ); returnData.push(...executionData); } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({error: error.message}), - { itemData: {item: i} }, + this.helpers.returnJsonArray({ error: error.message }), + { itemData: { item: i } }, ); returnData.push(...executionData); continue; @@ -435,7 +435,7 @@ export class SendGrid implements INodeType { } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({error: error.message}), + this.helpers.returnJsonArray({ error: error.message }), { itemData: { item: i } }, ); returnData.push(...executionData); @@ -496,7 +496,7 @@ export class SendGrid implements INodeType { } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({error: error.message}), + this.helpers.returnJsonArray({ error: error.message }), { itemData: { item: i } }, ); returnData.push(...executionData); diff --git a/packages/nodes-base/nodes/SentryIo/SentryIo.node.ts b/packages/nodes-base/nodes/SentryIo/SentryIo.node.ts index dfcacd3bf6f24..72ef6a9614561 100644 --- a/packages/nodes-base/nodes/SentryIo/SentryIo.node.ts +++ b/packages/nodes-base/nodes/SentryIo/SentryIo.node.ts @@ -297,7 +297,7 @@ export class SentryIo implements INodeType { const organizationSlug = this.getNodeParameter('organizationSlug', i) as string; const projectSlug = this.getNodeParameter('projectSlug', i) as string; const full = this.getNodeParameter('full', i) as boolean; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const endpoint = `/api/0/projects/${organizationSlug}/${projectSlug}/events/`; @@ -329,7 +329,7 @@ export class SentryIo implements INodeType { if (operation === 'getAll') { const organizationSlug = this.getNodeParameter('organizationSlug', i) as string; const projectSlug = this.getNodeParameter('projectSlug', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const endpoint = `/api/0/projects/${organizationSlug}/${projectSlug}/issues/`; @@ -406,7 +406,7 @@ export class SentryIo implements INodeType { responseData = await sentryIoApiRequest.call(this, 'GET', endpoint, qs); } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const endpoint = `/api/0/organizations/`; @@ -480,7 +480,7 @@ export class SentryIo implements INodeType { responseData = await sentryIoApiRequest.call(this, 'GET', endpoint, qs); } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const endpoint = `/api/0/projects/`; if (returnAll === false) { @@ -524,7 +524,7 @@ export class SentryIo implements INodeType { const organizationSlug = this.getNodeParameter('organizationSlug', i) as string; const endpoint = `/api/0/organizations/${organizationSlug}/releases/`; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (additionalFields.query) { qs.query = additionalFields.query as string; @@ -677,7 +677,7 @@ export class SentryIo implements INodeType { if (operation === 'getAll') { const organizationSlug = this.getNodeParameter('organizationSlug', i) as string; const endpoint = `/api/0/organizations/${organizationSlug}/teams/`; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { const limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/ServiceNow/ServiceNow.node.ts b/packages/nodes-base/nodes/ServiceNow/ServiceNow.node.ts index 9d39ff8d76e4f..b1795c48d9437 100644 --- a/packages/nodes-base/nodes/ServiceNow/ServiceNow.node.ts +++ b/packages/nodes-base/nodes/ServiceNow/ServiceNow.node.ts @@ -518,7 +518,7 @@ export class ServiceNow implements INodeType { if (resource === 'attachment') { if (operation === 'get') { const attachmentsSysId = this.getNodeParameter('attachmentId', i) as string; - const download = this.getNodeParameter('download', i) as boolean; + const download = this.getNodeParameter('download', i); const endpoint = `/now/attachment/${attachmentsSysId}`; const response = await serviceNowApiRequest.call(this, 'GET', endpoint, {}); @@ -543,9 +543,9 @@ export class ServiceNow implements INodeType { }; } } else if (operation === 'getAll') { - const download = this.getNodeParameter('download', i) as boolean; + const download = this.getNodeParameter('download', i); const tableName = this.getNodeParameter('tableName', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; qs = {} as IDataObject; @@ -649,7 +649,7 @@ export class ServiceNow implements INodeType { } } else if (resource === 'businessService') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { @@ -679,7 +679,7 @@ export class ServiceNow implements INodeType { } } else if (resource === 'configurationItems') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { @@ -709,7 +709,7 @@ export class ServiceNow implements INodeType { } } else if (resource === 'department') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { @@ -739,7 +739,7 @@ export class ServiceNow implements INodeType { } } else if (resource === 'dictionary') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { @@ -808,7 +808,7 @@ export class ServiceNow implements INodeType { ); responseData = response.result; } else if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { @@ -911,7 +911,7 @@ export class ServiceNow implements INodeType { responseData = response.result; } else if (operation === 'getAll') { const tableName = this.getNodeParameter('tableName', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { @@ -1026,7 +1026,7 @@ export class ServiceNow implements INodeType { responseData = response.result; } } else if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { @@ -1073,7 +1073,7 @@ export class ServiceNow implements INodeType { } } else if (resource === 'userGroup') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { @@ -1109,7 +1109,7 @@ export class ServiceNow implements INodeType { } } else if (resource === 'userRole') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); qs = this.getNodeParameter('options', i) as IDataObject; if (qs.sysparm_fields && typeof qs.sysparm_fields !== 'string') { diff --git a/packages/nodes-base/nodes/Shopify/Shopify.node.ts b/packages/nodes-base/nodes/Shopify/Shopify.node.ts index 44a3ad6aa846f..6df80a54f82ad 100644 --- a/packages/nodes-base/nodes/Shopify/Shopify.node.ts +++ b/packages/nodes-base/nodes/Shopify/Shopify.node.ts @@ -264,7 +264,7 @@ export class Shopify implements INodeType { } //https://shopify.dev/docs/admin-api/rest/reference/orders/order#index-2020-04 if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.fields) { qs.fields = options.fields as string; @@ -419,7 +419,7 @@ export class Shopify implements INodeType { {}, ) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); Object.assign(qs, additionalFields); diff --git a/packages/nodes-base/nodes/Slack/Slack.node.ts b/packages/nodes-base/nodes/Slack/Slack.node.ts index 67c58170dc83d..e842d48a9dd54 100644 --- a/packages/nodes-base/nodes/Slack/Slack.node.ts +++ b/packages/nodes-base/nodes/Slack/Slack.node.ts @@ -363,7 +363,7 @@ export class Slack implements INodeType { } //https://api.slack.com/methods/conversations.list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.types) { qs.types = (filters.types as string[]).join(','); @@ -389,7 +389,7 @@ export class Slack implements INodeType { //https://api.slack.com/methods/conversations.history if (operation === 'history') { const channel = this.getNodeParameter('channelId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; qs.channel = channel; if (filters.inclusive) { @@ -455,8 +455,8 @@ export class Slack implements INodeType { } //https://api.slack.com/methods/conversations.members if (operation === 'member') { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; - const resolveData = this.getNodeParameter('resolveData', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); + const resolveData = this.getNodeParameter('resolveData', 0); qs.channel = this.getNodeParameter('channelId', i) as string; if (returnAll) { responseData = await slackApiRequestAllItems.call( @@ -538,7 +538,7 @@ export class Slack implements INodeType { if (operation === 'replies') { const channel = this.getNodeParameter('channelId', i) as string; const ts = this.getNodeParameter('ts', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; qs.channel = channel; qs.ts = ts; @@ -639,7 +639,7 @@ export class Slack implements INodeType { action = 'postEphemeral'; } - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (authentication === 'accessToken' && sendAsUser !== '') { body.username = sendAsUser; @@ -1052,7 +1052,7 @@ export class Slack implements INodeType { } //https://api.slack.com/methods/stars.list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await slackApiRequestAllItems.call( this, @@ -1073,7 +1073,7 @@ export class Slack implements INodeType { //https://api.slack.com/methods/files.upload if (operation === 'upload') { const options = this.getNodeParameter('options', i) as IDataObject; - const binaryData = this.getNodeParameter('binaryData', i) as boolean; + const binaryData = this.getNodeParameter('binaryData', i); const body: IDataObject = {}; if (options.channelIds) { body.channels = (options.channelIds as string[]).join(','); @@ -1144,7 +1144,7 @@ export class Slack implements INodeType { } //https://api.slack.com/methods/files.list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.channelId) { qs.channel = filters.channelId as string; @@ -1196,7 +1196,7 @@ export class Slack implements INodeType { } //https://api.slack.com/methods/users.list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll === true) { responseData = await slackApiRequestAllItems.call( this, @@ -1276,7 +1276,7 @@ export class Slack implements INodeType { //https://api.slack.com/methods/usergroups.list if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; diff --git a/packages/nodes-base/nodes/Spotify/Spotify.node.ts b/packages/nodes-base/nodes/Spotify/Spotify.node.ts index 0889814ebd49f..31ffed0fb90e6 100644 --- a/packages/nodes-base/nodes/Spotify/Spotify.node.ts +++ b/packages/nodes-base/nodes/Spotify/Spotify.node.ts @@ -821,7 +821,7 @@ export class Spotify implements INodeType { endpoint = `/me/player/recently-played`; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); propertyName = 'items'; @@ -933,7 +933,7 @@ export class Spotify implements INodeType { Object.assign(qs, filters); } - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (!returnAll) { qs.limit = this.getNodeParameter('limit', i); @@ -951,7 +951,7 @@ export class Spotify implements INodeType { propertyName = 'tracks'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); propertyName = 'items'; @@ -973,7 +973,7 @@ export class Spotify implements INodeType { propertyName = 'albums.items'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); const q = this.getNodeParameter('query', i) as string; const filters = this.getNodeParameter('filters', i) as IDataObject; @@ -1002,7 +1002,7 @@ export class Spotify implements INodeType { if (operation === 'getAlbums') { endpoint = `/artists/${id}/albums`; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); propertyName = 'items'; @@ -1048,7 +1048,7 @@ export class Spotify implements INodeType { propertyName = 'artists.items'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); const q = this.getNodeParameter('query', i) as string; const filters = this.getNodeParameter('filters', i) as IDataObject; @@ -1102,7 +1102,7 @@ export class Spotify implements INodeType { endpoint = `/playlists/${id}/tracks`; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); propertyName = 'items'; @@ -1146,7 +1146,7 @@ export class Spotify implements INodeType { endpoint = '/me/playlists'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); propertyName = 'items'; @@ -1180,7 +1180,7 @@ export class Spotify implements INodeType { propertyName = 'playlists.items'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); const q = this.getNodeParameter('query', i) as string; const filters = this.getNodeParameter('filters', i) as IDataObject; @@ -1222,7 +1222,7 @@ export class Spotify implements INodeType { propertyName = 'tracks.items'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); const q = this.getNodeParameter('query', i) as string; const filters = this.getNodeParameter('filters', i) as IDataObject; @@ -1250,7 +1250,7 @@ export class Spotify implements INodeType { endpoint = '/me/tracks'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); propertyName = 'items'; @@ -1272,7 +1272,7 @@ export class Spotify implements INodeType { endpoint = `/me/following`; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); propertyName = 'artists.items'; @@ -1323,4 +1323,4 @@ export class Spotify implements INodeType { return this.prepareOutputData(returnData); } -} \ No newline at end of file +} diff --git a/packages/nodes-base/nodes/Stackby/Stackby.node.ts b/packages/nodes-base/nodes/Stackby/Stackby.node.ts index 8b1b075055b35..f7898d4101182 100644 --- a/packages/nodes-base/nodes/Stackby/Stackby.node.ts +++ b/packages/nodes-base/nodes/Stackby/Stackby.node.ts @@ -301,7 +301,7 @@ export class Stackby implements INodeType { try { const stackId = this.getNodeParameter('stackId', i) as string; const table = encodeURI(this.getNodeParameter('table', i) as string); - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const additionalFields = this.getNodeParameter('additionalFields', i, {}) as IDataObject; diff --git a/packages/nodes-base/nodes/Storyblok/Storyblok.node.ts b/packages/nodes-base/nodes/Storyblok/Storyblok.node.ts index c135e8bffed58..0654458f3f559 100644 --- a/packages/nodes-base/nodes/Storyblok/Storyblok.node.ts +++ b/packages/nodes-base/nodes/Storyblok/Storyblok.node.ts @@ -171,7 +171,7 @@ export class Storyblok implements INodeType { } if (operation === 'getAll') { const filters = this.getNodeParameter('filters', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); Object.assign(qs, filters); if (returnAll) { @@ -204,7 +204,7 @@ export class Storyblok implements INodeType { // const space = this.getNodeParameter('space', i) as string; // const name = this.getNodeParameter('name', i) as string; // const slug = this.getNodeParameter('slug', i) as string; - // const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + // const jsonParameters = this.getNodeParameter('jsonParameters', i); // const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; // const body: IDataObject = { // name, @@ -281,7 +281,7 @@ export class Storyblok implements INodeType { if (operation === 'getAll') { const space = this.getNodeParameter('space', i) as string; const filters = this.getNodeParameter('filters', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); Object.assign(qs, filters); if (returnAll) { diff --git a/packages/nodes-base/nodes/Strapi/Strapi.node.ts b/packages/nodes-base/nodes/Strapi/Strapi.node.ts index 09588c5a6094a..d3876e797eb6a 100644 --- a/packages/nodes-base/nodes/Strapi/Strapi.node.ts +++ b/packages/nodes-base/nodes/Strapi/Strapi.node.ts @@ -177,7 +177,7 @@ export class Strapi implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const contentType = this.getNodeParameter('contentType', i) as string; diff --git a/packages/nodes-base/nodes/Strava/Strava.node.ts b/packages/nodes-base/nodes/Strava/Strava.node.ts index 3ea98d4ea79de..d867967b4f9e4 100644 --- a/packages/nodes-base/nodes/Strava/Strava.node.ts +++ b/packages/nodes-base/nodes/Strava/Strava.node.ts @@ -105,7 +105,7 @@ export class Strava implements INodeType { const activityId = this.getNodeParameter('activityId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); responseData = await stravaApiRequest.call( this, @@ -135,7 +135,7 @@ export class Strava implements INodeType { } //https://developers.mailerlite.com/reference#subscribers if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await stravaApiRequestAllItems.call( diff --git a/packages/nodes-base/nodes/Stripe/helpers.ts b/packages/nodes-base/nodes/Stripe/helpers.ts index 0e365f7d0258a..7d9ec333bacc9 100644 --- a/packages/nodes-base/nodes/Stripe/helpers.ts +++ b/packages/nodes-base/nodes/Stripe/helpers.ts @@ -118,7 +118,7 @@ export async function handleListing( const returnData: IDataObject[] = []; let responseData; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const limit = this.getNodeParameter('limit', i, 0) as number; do { diff --git a/packages/nodes-base/nodes/Supabase/Supabase.node.ts b/packages/nodes-base/nodes/Supabase/Supabase.node.ts index b3d3ef6dcc9da..99f75aacc0904 100644 --- a/packages/nodes-base/nodes/Supabase/Supabase.node.ts +++ b/packages/nodes-base/nodes/Supabase/Supabase.node.ts @@ -247,7 +247,7 @@ export class Supabase implements INodeType { if (operation === 'getAll') { const tableId = this.getNodeParameter('tableId', 0) as string; - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const filterType = this.getNodeParameter('filterType', 0) as string; let endpoint = `/${tableId}`; for (let i = 0; i < length; i++) { diff --git a/packages/nodes-base/nodes/Taiga/GenericFunctions.ts b/packages/nodes-base/nodes/Taiga/GenericFunctions.ts index 73870df262a58..82067cbbe6acc 100644 --- a/packages/nodes-base/nodes/Taiga/GenericFunctions.ts +++ b/packages/nodes-base/nodes/Taiga/GenericFunctions.ts @@ -145,7 +145,7 @@ export async function handleListing( ) { let responseData; qs.project = this.getNodeParameter('projectId', i) as number; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { return await taigaApiRequestAllItems.call(this, method, endpoint, body, qs); diff --git a/packages/nodes-base/nodes/Tapfiliate/Tapfiliate.node.ts b/packages/nodes-base/nodes/Tapfiliate/Tapfiliate.node.ts index 8a6c130aa4b98..ae0aeaf5b3e21 100644 --- a/packages/nodes-base/nodes/Tapfiliate/Tapfiliate.node.ts +++ b/packages/nodes-base/nodes/Tapfiliate/Tapfiliate.node.ts @@ -154,7 +154,7 @@ export class Tapfiliate implements INodeType { } if (operation === 'getAll') { //https://tapfiliate.com/docs/rest/#affiliates-affiliates-collection-get - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; Object.assign(qs, filters); if (returnAll) { @@ -271,7 +271,7 @@ export class Tapfiliate implements INodeType { if (operation === 'getAll') { //https://tapfiliate.com/docs/rest/#programs-program-affiliates-collection-get const programId = this.getNodeParameter('programId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; Object.assign(qs, filters); if (returnAll) { diff --git a/packages/nodes-base/nodes/Telegram/Telegram.node.ts b/packages/nodes-base/nodes/Telegram/Telegram.node.ts index 827d300d3ea67..d0b0f15ffa82b 100644 --- a/packages/nodes-base/nodes/Telegram/Telegram.node.ts +++ b/packages/nodes-base/nodes/Telegram/Telegram.node.ts @@ -1685,7 +1685,7 @@ export class Telegram implements INodeType { const operation = this.getNodeParameter('operation', 0) as string; const resource = this.getNodeParameter('resource', 0) as string; - const binaryData = this.getNodeParameter('binaryData', 0, false) as boolean; + const binaryData = this.getNodeParameter('binaryData', 0, false); for (let i = 0; i < items.length; i++) { try { @@ -2018,7 +2018,7 @@ export class Telegram implements INodeType { } if (resource === 'file' && operation === 'get') { - if ((this.getNodeParameter('download', i, false) as boolean) === true) { + if (this.getNodeParameter('download', i, false) === true) { const filePath = responseData.result.file_path; const credentials = await this.getCredentials('telegramApi'); @@ -2060,7 +2060,6 @@ export class Telegram implements INodeType { continue; } - const executionData = this.helpers.constructExecutionMetaData( this.helpers.returnJsonArray(responseData), { itemData: { item: i } }, @@ -2068,7 +2067,7 @@ export class Telegram implements INodeType { returnData.push(...executionData); } catch (error) { if (this.continueOnFail()) { - returnData.push({ json: { }, error: error.message }); + returnData.push({ json: {}, error: error.message }); continue; } throw error; diff --git a/packages/nodes-base/nodes/TheHive/TheHive.node.ts b/packages/nodes-base/nodes/TheHive/TheHive.node.ts index fa36381eac9d3..50052cde94c7b 100644 --- a/packages/nodes-base/nodes/TheHive/TheHive.node.ts +++ b/packages/nodes-base/nodes/TheHive/TheHive.node.ts @@ -377,7 +377,7 @@ export class TheHive implements INodeType { 'additionalFields', i, ) as INodeParameters; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const customFields = await prepareCustomFields.call( this, @@ -531,7 +531,7 @@ export class TheHive implements INodeType { if (operation === 'getAll') { const credentials = await this.getCredentials('theHiveApi'); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const version = credentials.apiVersion; @@ -670,7 +670,7 @@ export class TheHive implements INodeType { if (operation === 'update') { const alertId = this.getNodeParameter('id', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const updateFields = this.getNodeParameter('updateFields', i) as IDataObject; const customFields = await prepareCustomFields.call(this, updateFields, jsonParameters); @@ -995,7 +995,7 @@ export class TheHive implements INodeType { if (operation === 'getAll') { const credentials = await this.getCredentials('theHiveApi'); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const version = credentials.apiVersion; @@ -1061,7 +1061,7 @@ export class TheHive implements INodeType { if (operation === 'search') { const credentials = await this.getCredentials('theHiveApi'); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const version = credentials.apiVersion; @@ -1275,7 +1275,7 @@ export class TheHive implements INodeType { if (operation === 'create') { const options = this.getNodeParameter('options', i, {}) as INodeParameters; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const customFields = await prepareCustomFields.call(this, options, jsonParameters); const body: IDataObject = { @@ -1339,7 +1339,7 @@ export class TheHive implements INodeType { if (operation === 'getAll') { const credentials = await this.getCredentials('theHiveApi'); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const version = credentials.apiVersion; @@ -1430,7 +1430,7 @@ export class TheHive implements INodeType { if (operation === 'update') { const id = this.getNodeParameter('id', i) as string; const updateFields = this.getNodeParameter('updateFields', i, {}) as INodeParameters; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const customFields = await prepareCustomFields.call(this, updateFields, jsonParameters); @@ -1600,7 +1600,7 @@ export class TheHive implements INodeType { // get all require a case id (it retursn all tasks for a specific case) const credentials = await this.getCredentials('theHiveApi'); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const version = credentials.apiVersion; @@ -1666,7 +1666,7 @@ export class TheHive implements INodeType { if (operation === 'search') { const credentials = await this.getCredentials('theHiveApi'); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const version = credentials.apiVersion; @@ -1920,7 +1920,7 @@ export class TheHive implements INodeType { if (operation === 'getAll') { const credentials = await this.getCredentials('theHiveApi'); - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const version = credentials.apiVersion; diff --git a/packages/nodes-base/nodes/TravisCi/TravisCi.node.ts b/packages/nodes-base/nodes/TravisCi/TravisCi.node.ts index c70c761b43fe7..fdba0ac8aa8c3 100644 --- a/packages/nodes-base/nodes/TravisCi/TravisCi.node.ts +++ b/packages/nodes-base/nodes/TravisCi/TravisCi.node.ts @@ -72,7 +72,7 @@ export class TravisCi implements INodeType { //https://developer.travis-ci.com/resource/builds#for_current_user if (operation === 'getAll') { const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (additionalFields.sortBy) { qs.sort_by = additionalFields.sortBy; diff --git a/packages/nodes-base/nodes/Trello/Trello.node.ts b/packages/nodes-base/nodes/Trello/Trello.node.ts index 5e5d434efcc45..06da9280b401f 100644 --- a/packages/nodes-base/nodes/Trello/Trello.node.ts +++ b/packages/nodes-base/nodes/Trello/Trello.node.ts @@ -282,7 +282,7 @@ export class Trello implements INodeType { requestMethod = 'GET'; const id = this.getNodeParameter('id', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; } @@ -497,7 +497,7 @@ export class Trello implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; @@ -516,7 +516,7 @@ export class Trello implements INodeType { requestMethod = 'GET'; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (returnAll === false) { qs.limit = this.getNodeParameter('limit', i) as number; diff --git a/packages/nodes-base/nodes/Twist/Twist.node.ts b/packages/nodes-base/nodes/Twist/Twist.node.ts index de402acd97bff..13a5255b0cd1b 100644 --- a/packages/nodes-base/nodes/Twist/Twist.node.ts +++ b/packages/nodes-base/nodes/Twist/Twist.node.ts @@ -192,7 +192,7 @@ export class Twist implements INodeType { //https://developer.twist.com/v3/#get-all-channels if (operation === 'getAll') { const workspaceId = this.getNodeParameter('workspaceId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; qs.workspace_id = workspaceId; Object.assign(qs, filters); @@ -320,7 +320,7 @@ export class Twist implements INodeType { //https://developer.twist.com/v3/#get-all-comments if (operation === 'getAll') { const threadId = this.getNodeParameter('threadId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; qs.thread_id = threadId; @@ -716,7 +716,7 @@ export class Twist implements INodeType { //https://developer.twist.com/v3/#get-all-threads if (operation === 'getAll') { const channelId = this.getNodeParameter('channelId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; qs.channel_id = channelId; diff --git a/packages/nodes-base/nodes/Twitter/Twitter.node.ts b/packages/nodes-base/nodes/Twitter/Twitter.node.ts index badf00deecbea..175a85173e543 100644 --- a/packages/nodes-base/nodes/Twitter/Twitter.node.ts +++ b/packages/nodes-base/nodes/Twitter/Twitter.node.ts @@ -215,7 +215,7 @@ export class Twitter implements INodeType { // https://developer.twitter.com/en/docs/tweets/search/api-reference/get-search-tweets if (operation === 'search') { const q = this.getNodeParameter('searchText', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; const qs: IDataObject = { q, diff --git a/packages/nodes-base/nodes/UnleashedSoftware/UnleashedSoftware.node.ts b/packages/nodes-base/nodes/UnleashedSoftware/UnleashedSoftware.node.ts index 5a871a1f69f1e..7bdd51386e801 100644 --- a/packages/nodes-base/nodes/UnleashedSoftware/UnleashedSoftware.node.ts +++ b/packages/nodes-base/nodes/UnleashedSoftware/UnleashedSoftware.node.ts @@ -75,7 +75,7 @@ export class UnleashedSoftware implements INodeType { //https://apidocs.unleashedsoftware.com/SalesOrders if (resource === 'salesOrder') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.startDate) { @@ -122,7 +122,7 @@ export class UnleashedSoftware implements INodeType { //https://apidocs.unleashedsoftware.com/StockOnHand if (resource === 'stockOnHand') { if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; diff --git a/packages/nodes-base/nodes/UptimeRobot/UptimeRobot.node.ts b/packages/nodes-base/nodes/UptimeRobot/UptimeRobot.node.ts index 44e7a5b295e88..0b5efcbfdc894 100644 --- a/packages/nodes-base/nodes/UptimeRobot/UptimeRobot.node.ts +++ b/packages/nodes-base/nodes/UptimeRobot/UptimeRobot.node.ts @@ -161,7 +161,7 @@ export class UptimeRobot implements INodeType { } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; body = { @@ -250,7 +250,7 @@ export class UptimeRobot implements INodeType { responseData = responseData.alert_contacts; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); body = { ...(this.getNodeParameter('filters', i) as IDataObject), @@ -327,7 +327,7 @@ export class UptimeRobot implements INodeType { responseData = responseData.mwindows; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); body = { ...(this.getNodeParameter('filters', i) as IDataObject), @@ -391,7 +391,7 @@ export class UptimeRobot implements INodeType { responseData = responseData.psps; } if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); body = { ...(this.getNodeParameter('filters', i) as IDataObject), diff --git a/packages/nodes-base/nodes/Venafi/Datacenter/VenafiTlsProtectDatacenter.node.ts b/packages/nodes-base/nodes/Venafi/Datacenter/VenafiTlsProtectDatacenter.node.ts index 081ac300bb016..a26072be3c8fc 100644 --- a/packages/nodes-base/nodes/Venafi/Datacenter/VenafiTlsProtectDatacenter.node.ts +++ b/packages/nodes-base/nodes/Venafi/Datacenter/VenafiTlsProtectDatacenter.node.ts @@ -64,7 +64,6 @@ export class VenafiTlsProtectDatacenter implements INodeType { for (let i = 0; i < length; i++) { try { if (resource === 'certificate') { - if (operation === 'create') { const policyDN = this.getNodeParameter('PolicyDN', i) as string; @@ -158,7 +157,7 @@ export class VenafiTlsProtectDatacenter implements INodeType { } if (operation === 'getMany') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; @@ -237,7 +236,6 @@ export class VenafiTlsProtectDatacenter implements INodeType { itemData: { item: i }, }), ); - } catch (error) { if (this.continueOnFail()) { returnData.push({ json: { error: error.message } }); diff --git a/packages/nodes-base/nodes/Venafi/ProtectCloud/VenafiTlsProtectCloud.node.ts b/packages/nodes-base/nodes/Venafi/ProtectCloud/VenafiTlsProtectCloud.node.ts index 8ac098710f86e..63e5c4bde7b1a 100644 --- a/packages/nodes-base/nodes/Venafi/ProtectCloud/VenafiTlsProtectCloud.node.ts +++ b/packages/nodes-base/nodes/Venafi/ProtectCloud/VenafiTlsProtectCloud.node.ts @@ -265,7 +265,7 @@ export class VenafiTlsProtectCloud implements INodeType { //https://api.venafi.cloud/webjars/swagger-ui/index.html?configUrl=/v3/api-docs/swagger-config&urls.primaryName=outagedetection-service#//v1/certificaterequests_getAll if (operation === 'getMany') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await venafiApiRequestAllItems.call( @@ -405,7 +405,7 @@ export class VenafiTlsProtectCloud implements INodeType { //https://api.venafi.cloud/webjars/swagger-ui/index.html?configUrl=%2Fv3%2Fapi-docs%2Fswagger-config&urls.primaryName=outagedetection-service#/%2Fv1/certificates_getAllAsCsv if (operation === 'getMany') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; Object.assign(qs, filters); diff --git a/packages/nodes-base/nodes/Vero/Vero.node.ts b/packages/nodes-base/nodes/Vero/Vero.node.ts index 3d84bda629386..57fab1c97a96a 100644 --- a/packages/nodes-base/nodes/Vero/Vero.node.ts +++ b/packages/nodes-base/nodes/Vero/Vero.node.ts @@ -72,7 +72,7 @@ export class Vero implements INodeType { if (operation === 'create') { const id = this.getNodeParameter('id', i) as string; const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); const body = { id, }; @@ -170,7 +170,7 @@ export class Vero implements INodeType { const id = this.getNodeParameter('id', i) as string; const email = this.getNodeParameter('email', i) as string; const eventName = this.getNodeParameter('eventName', i) as string; - const jsonActive = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonActive = this.getNodeParameter('jsonParameters', i); const body = { identity: { id, email }, event_name: eventName, diff --git a/packages/nodes-base/nodes/Webflow/Webflow.node.ts b/packages/nodes-base/nodes/Webflow/Webflow.node.ts index f2cef266c9896..91fa727c293b8 100644 --- a/packages/nodes-base/nodes/Webflow/Webflow.node.ts +++ b/packages/nodes-base/nodes/Webflow/Webflow.node.ts @@ -215,7 +215,7 @@ export class Webflow implements INodeType { // https://developers.webflow.com/#get-all-items-for-a-collection - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); const collectionId = this.getNodeParameter('collectionId', i) as string; const qs: IDataObject = {}; diff --git a/packages/nodes-base/nodes/Wekan/Wekan.node.ts b/packages/nodes-base/nodes/Wekan/Wekan.node.ts index a9e011fdd90d5..797cc695827dc 100644 --- a/packages/nodes-base/nodes/Wekan/Wekan.node.ts +++ b/packages/nodes-base/nodes/Wekan/Wekan.node.ts @@ -300,7 +300,7 @@ export class Wekan implements INodeType { const userId = this.getNodeParameter('IdUser', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); endpoint = `users/${userId}/boards`; } else { @@ -362,7 +362,7 @@ export class Wekan implements INodeType { const boardId = this.getNodeParameter('boardId', i) as string; const fromObject = this.getNodeParameter('fromObject', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); if (fromObject === 'list') { const listId = this.getNodeParameter('listId', i) as string; @@ -497,7 +497,7 @@ export class Wekan implements INodeType { requestMethod = 'GET'; const boardId = this.getNodeParameter('boardId', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); endpoint = `boards/${boardId}/lists`; } else { @@ -556,7 +556,7 @@ export class Wekan implements INodeType { const boardId = this.getNodeParameter('boardId', i) as string; const cardId = this.getNodeParameter('cardId', i) as string; - returnAll = this.getNodeParameter('returnAll', i) as boolean; + returnAll = this.getNodeParameter('returnAll', i); endpoint = `boards/${boardId}/cards/${cardId}/checklists`; } else if (operation === 'getCheckItem') { diff --git a/packages/nodes-base/nodes/WooCommerce/WooCommerce.node.ts b/packages/nodes-base/nodes/WooCommerce/WooCommerce.node.ts index acee548d55705..71a8dcc061be4 100644 --- a/packages/nodes-base/nodes/WooCommerce/WooCommerce.node.ts +++ b/packages/nodes-base/nodes/WooCommerce/WooCommerce.node.ts @@ -190,7 +190,7 @@ export class WooCommerce implements INodeType { const qs = {} as IDataObject; const filters = this.getNodeParameter('filters', i) as IDataObject; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (Object.keys(filters).length) { Object.assign(qs, filters); @@ -304,7 +304,7 @@ export class WooCommerce implements INodeType { } //https://woocommerce.github.io/woocommerce-rest-api-docs/#list-all-products if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.after) { qs.after = options.after as string; @@ -530,7 +530,7 @@ export class WooCommerce implements INodeType { } //https://woocommerce.github.io/woocommerce-rest-api-docs/#list-all-orders if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.after) { qs.after = options.after as string; diff --git a/packages/nodes-base/nodes/Wordpress/Wordpress.node.ts b/packages/nodes-base/nodes/Wordpress/Wordpress.node.ts index f02177090fa90..cbae44aea0fca 100644 --- a/packages/nodes-base/nodes/Wordpress/Wordpress.node.ts +++ b/packages/nodes-base/nodes/Wordpress/Wordpress.node.ts @@ -244,7 +244,7 @@ export class Wordpress implements INodeType { } //https://developer.wordpress.org/rest-api/reference/posts/#list-posts if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.context) { qs.context = options.context as string; @@ -387,7 +387,7 @@ export class Wordpress implements INodeType { } //https://developer.wordpress.org/rest-api/reference/users/#list-users if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.context) { qs.context = options.context as string; diff --git a/packages/nodes-base/nodes/Xero/Xero.node.ts b/packages/nodes-base/nodes/Xero/Xero.node.ts index 27efa06902897..ce7dee702b04f 100644 --- a/packages/nodes-base/nodes/Xero/Xero.node.ts +++ b/packages/nodes-base/nodes/Xero/Xero.node.ts @@ -419,7 +419,7 @@ export class Xero implements INodeType { } if (operation === 'getAll') { const organizationId = this.getNodeParameter('organizationId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.statuses) { qs.statuses = (options.statuses as string[]).join(','); @@ -575,7 +575,7 @@ export class Xero implements INodeType { } if (operation === 'getAll') { const organizationId = this.getNodeParameter('organizationId', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; if (options.includeArchived) { qs.includeArchived = options.includeArchived as boolean; diff --git a/packages/nodes-base/nodes/Zammad/Zammad.node.ts b/packages/nodes-base/nodes/Zammad/Zammad.node.ts index 48ddd38a7eae1..ef6d1985a1202 100644 --- a/packages/nodes-base/nodes/Zammad/Zammad.node.ts +++ b/packages/nodes-base/nodes/Zammad/Zammad.node.ts @@ -432,7 +432,7 @@ export class Zammad implements INodeType { qs.query ||= ''; // otherwise triggers 500 - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const limit = returnAll ? 0 : (this.getNodeParameter('limit', i) as number); @@ -540,7 +540,7 @@ export class Zammad implements INodeType { // https://docs.zammad.org/en/latest/api/organization.html#list // https://docs.zammad.org/en/latest/api/organization.html#search - returning empty always - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const limit = returnAll ? 0 : (this.getNodeParameter('limit', i) as number); @@ -639,7 +639,7 @@ export class Zammad implements INodeType { // https://docs.zammad.org/en/latest/api/group.html#list - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const limit = returnAll ? 0 : (this.getNodeParameter('limit', i) as number); @@ -730,7 +730,7 @@ export class Zammad implements INodeType { // https://docs.zammad.org/en/latest/api/ticket/index.html#list // https://docs.zammad.org/en/latest/api/ticket/index.html#search - returning empty always - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const limit = returnAll ? 0 : (this.getNodeParameter('limit', i) as number); diff --git a/packages/nodes-base/nodes/Zendesk/Zendesk.node.ts b/packages/nodes-base/nodes/Zendesk/Zendesk.node.ts index 34b660ba1b349..c895eb7b7451d 100644 --- a/packages/nodes-base/nodes/Zendesk/Zendesk.node.ts +++ b/packages/nodes-base/nodes/Zendesk/Zendesk.node.ts @@ -277,7 +277,7 @@ export class Zendesk implements INodeType { //https://developer.zendesk.com/rest_api/docs/support/tickets if (operation === 'create') { const description = this.getNodeParameter('description', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const comment: IComment = { body: description, }; @@ -336,7 +336,7 @@ export class Zendesk implements INodeType { //https://developer.zendesk.com/rest_api/docs/support/tickets#update-ticket if (operation === 'update') { const ticketId = this.getNodeParameter('id', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const body: ITicket = {}; if (jsonParameters) { @@ -419,7 +419,7 @@ export class Zendesk implements INodeType { //https://developer.zendesk.com/api-reference/ticketing/tickets/suspended_tickets/#list-suspended-tickets if (operation === 'getAll') { const ticketType = this.getNodeParameter('ticketType', i) as string; - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('options', i) as IDataObject; qs.query = 'type:ticket'; if (options.query) { @@ -497,7 +497,7 @@ export class Zendesk implements INodeType { } //https://developer.zendesk.com/rest_api/docs/support/ticket_fields#list-ticket-fields if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await zendeskApiRequestAllItems.call( this, @@ -585,7 +585,7 @@ export class Zendesk implements INodeType { } //https://developer.zendesk.com/api-reference/ticketing/users/users/#list-users if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('filters', i) as IDataObject; Object.assign(qs, options); @@ -619,7 +619,7 @@ export class Zendesk implements INodeType { } //https://developer.zendesk.com/api-reference/ticketing/users/users/#search-users if (operation === 'search') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const options = this.getNodeParameter('filters', i) as IDataObject; Object.assign(qs, options); @@ -721,7 +721,7 @@ export class Zendesk implements INodeType { } //https://developer.zendesk.com/api-reference/ticketing/organizations/organizations/#list-organizations if (operation === 'getAll') { - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); if (returnAll) { responseData = await zendeskApiRequestAllItems.call( diff --git a/packages/nodes-base/nodes/Zoho/GenericFunctions.ts b/packages/nodes-base/nodes/Zoho/GenericFunctions.ts index 367bd35993635..a61a8aa026eea 100644 --- a/packages/nodes-base/nodes/Zoho/GenericFunctions.ts +++ b/packages/nodes-base/nodes/Zoho/GenericFunctions.ts @@ -101,7 +101,7 @@ export async function handleListing( body: IDataObject = {}, qs: IDataObject = {}, ) { - const returnAll = this.getNodeParameter('returnAll', 0) as boolean; + const returnAll = this.getNodeParameter('returnAll', 0); if (returnAll) { return await zohoApiRequestAllItems.call(this, method, endpoint, body, qs); diff --git a/packages/nodes-base/nodes/Zoom/Zoom.node.ts b/packages/nodes-base/nodes/Zoom/Zoom.node.ts index 14025f4fd5a16..c2fd2bd48aa8b 100644 --- a/packages/nodes-base/nodes/Zoom/Zoom.node.ts +++ b/packages/nodes-base/nodes/Zoom/Zoom.node.ts @@ -181,7 +181,7 @@ export class Zoom implements INodeType { } if (operation === 'getAll') { //https://marketplace.zoom.us/docs/api-reference/zoom-api/meetings/meetings - const returnAll = this.getNodeParameter('returnAll', i) as boolean; + const returnAll = this.getNodeParameter('returnAll', i); const filters = this.getNodeParameter('filters', i) as IDataObject; if (filters.type) { @@ -495,7 +495,7 @@ export class Zoom implements INodeType { // if (additionalFields.status) { // qs.status = additionalFields.status as string; // } - // const returnAll = this.getNodeParameter('returnAll', i) as boolean; + // const returnAll = this.getNodeParameter('returnAll', i); // if (returnAll) { // responseData = await zoomApiRequestAllItems.call(this, 'results', 'GET', `/meetings/${meetingId}/registrants`, {}, qs); // } else { @@ -648,7 +648,7 @@ export class Zoom implements INodeType { // if (operation === 'getAll') { // //https://marketplace.zoom.us/docs/api-reference/zoom-api/webinars/webinars // const userId = this.getNodeParameter('userId', i) as string; - // const returnAll = this.getNodeParameter('returnAll', i) as boolean; + // const returnAll = this.getNodeParameter('returnAll', i); // if (returnAll) { // responseData = await zoomApiRequestAllItems.call(this, 'results', 'GET', `/users/${userId}/webinars`, {}, qs); // } else { diff --git a/packages/nodes-base/nodes/Zulip/Zulip.node.ts b/packages/nodes-base/nodes/Zulip/Zulip.node.ts index 8e35bdd3be73e..48608398e5881 100644 --- a/packages/nodes-base/nodes/Zulip/Zulip.node.ts +++ b/packages/nodes-base/nodes/Zulip/Zulip.node.ts @@ -270,7 +270,7 @@ export class Zulip implements INodeType { } if (operation === 'create') { - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); const subscriptions = this.getNodeParameter('subscriptions', i) as IDataObject; body.subscriptions = JSON.stringify(subscriptions.properties); @@ -342,7 +342,7 @@ export class Zulip implements INodeType { if (operation === 'update') { const streamId = this.getNodeParameter('streamId', i) as string; - const jsonParameters = this.getNodeParameter('jsonParameters', i) as boolean; + const jsonParameters = this.getNodeParameter('jsonParameters', i); if (jsonParameters) { const additionalFieldsJson = this.getNodeParameter( From 6b2b4f4f7bc6d8173068315cfa275676ac7de388 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Fri, 18 Nov 2022 14:10:40 +0100 Subject: [PATCH 4/4] :rewind: Undo autoformatting --- .../nodes-base/nodes/Gotify/Gotify.node.ts | 3 ++- .../nodes/Pipedrive/Pipedrive.node.ts | 2 +- .../nodes-base/nodes/SendGrid/SendGrid.node.ts | 18 +++++++++--------- 3 files changed, 12 insertions(+), 11 deletions(-) diff --git a/packages/nodes-base/nodes/Gotify/Gotify.node.ts b/packages/nodes-base/nodes/Gotify/Gotify.node.ts index b67bc48cfbfad..cabf035e8e8b5 100644 --- a/packages/nodes-base/nodes/Gotify/Gotify.node.ts +++ b/packages/nodes-base/nodes/Gotify/Gotify.node.ts @@ -213,9 +213,10 @@ export class Gotify implements INodeType { { itemData: { item: i } }, ); returnData.push(...executionData); + } catch (error) { if (this.continueOnFail()) { - returnData.push({ json: { error: error.message } }); + returnData.push({json:{ error: error.message }}); continue; } throw error; diff --git a/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts b/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts index 89c577a4068e7..3494e072b114b 100644 --- a/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts +++ b/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts @@ -4890,7 +4890,7 @@ export class Pipedrive implements INodeType { if (resource === 'file' && operation === 'download') { items[i].json = { error: error.message }; } else { - returnData.push({ json: { error: error.message } }); + returnData.push({json:{ error: error.message }}); } continue; } diff --git a/packages/nodes-base/nodes/SendGrid/SendGrid.node.ts b/packages/nodes-base/nodes/SendGrid/SendGrid.node.ts index 038fac10a6c38..66c965beabac3 100644 --- a/packages/nodes-base/nodes/SendGrid/SendGrid.node.ts +++ b/packages/nodes-base/nodes/SendGrid/SendGrid.node.ts @@ -337,8 +337,8 @@ export class SendGrid implements INodeType { } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({ error: error.message }), - { itemData: { item: i } }, + this.helpers.returnJsonArray({error: error.message}), + { itemData: {item: i} }, ); returnData.push(...executionData); continue; @@ -374,8 +374,8 @@ export class SendGrid implements INodeType { } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({ error: error.message }), - { itemData: { item: i } }, + this.helpers.returnJsonArray({error: error.message}), + { itemData: {item: i} }, ); returnData.push(...executionData); continue; @@ -399,14 +399,14 @@ export class SendGrid implements INodeType { const executionData = this.helpers.constructExecutionMetaData( this.helpers.returnJsonArray(responseData), - { itemData: { item: i } }, + { itemData: {item: i} }, ); returnData.push(...executionData); } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({ error: error.message }), - { itemData: { item: i } }, + this.helpers.returnJsonArray({error: error.message}), + { itemData: {item: i} }, ); returnData.push(...executionData); continue; @@ -435,7 +435,7 @@ export class SendGrid implements INodeType { } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({ error: error.message }), + this.helpers.returnJsonArray({error: error.message}), { itemData: { item: i } }, ); returnData.push(...executionData); @@ -496,7 +496,7 @@ export class SendGrid implements INodeType { } catch (error) { if (this.continueOnFail()) { const executionData = this.helpers.constructExecutionMetaData( - this.helpers.returnJsonArray({ error: error.message }), + this.helpers.returnJsonArray({error: error.message}), { itemData: { item: i } }, ); returnData.push(...executionData);