refactor: Reduce usage of IExecuteSingleFunctions (no-changelog) (#6944)

This commit is contained in:
Iván Ovejero
2023-08-16 15:52:41 +02:00
committed by GitHub
parent 3eb65e08c4
commit f50fc8443e
128 changed files with 158 additions and 409 deletions

View File

@@ -4,7 +4,6 @@ import type {
ICredentialDataDecryptedObject,
IDataObject,
IExecuteFunctions,
IExecuteSingleFunctions,
IHookFunctions,
ILoadOptionsFunctions,
IWebhookFunctions,
@@ -15,12 +14,7 @@ import { NodeApiError, NodeOperationError } from 'n8n-workflow';
import { createHash } from 'crypto';
export async function getAuthorization(
this:
| IHookFunctions
| IExecuteFunctions
| IExecuteSingleFunctions
| ILoadOptionsFunctions
| IWebhookFunctions,
this: IHookFunctions | IExecuteFunctions | ILoadOptionsFunctions | IWebhookFunctions,
credentials?: ICredentialDataDecryptedObject,
): Promise<string> {
if (credentials === undefined) {
@@ -50,12 +44,7 @@ export async function getAuthorization(
}
export async function taigaApiRequest(
this:
| IHookFunctions
| IExecuteFunctions
| IExecuteSingleFunctions
| ILoadOptionsFunctions
| IWebhookFunctions,
this: IHookFunctions | IExecuteFunctions | ILoadOptionsFunctions | IWebhookFunctions,
method: string,
resource: string,
body = {},