mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
refactor(core): Remove linting exceptions in nodes-base (no-changelog) (#4944)
This commit is contained in:
@@ -17,6 +17,12 @@ import { IDataObject, NodeApiError, NodeOperationError } from 'n8n-workflow';
|
||||
|
||||
import { URL } from 'url';
|
||||
|
||||
function queryToString(params: IDataObject) {
|
||||
return Object.keys(params)
|
||||
.map((key) => key + '=' + (params[key] as string))
|
||||
.join('&');
|
||||
}
|
||||
|
||||
export async function s3ApiRequest(
|
||||
this: IHookFunctions | IExecuteFunctions | ILoadOptionsFunctions | IWebhookFunctions,
|
||||
bucket: string,
|
||||
@@ -51,8 +57,8 @@ export async function s3ApiRequest(
|
||||
|
||||
// Sign AWS API request with the user credentials
|
||||
const signOpts = {
|
||||
headers: headers || {},
|
||||
region: region || credentials.region,
|
||||
headers: headers ?? {},
|
||||
region: region ?? credentials.region,
|
||||
host: endpoint.host,
|
||||
method,
|
||||
path: `${path}?${queryToString(query).replace(/\+/g, '%2B')}`,
|
||||
@@ -206,9 +212,3 @@ export async function s3ApiRequestSOAPAllItems(
|
||||
|
||||
return returnData;
|
||||
}
|
||||
|
||||
function queryToString(params: IDataObject) {
|
||||
return Object.keys(params)
|
||||
.map((key) => key + '=' + params[key])
|
||||
.join('&');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user