mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
refactor(core): All calls to supplyData should use a distinct context type (no-changelog) (#11421)
This commit is contained in:
committed by
GitHub
parent
04c075a46b
commit
8f5fe05a92
@@ -1,5 +1,10 @@
|
||||
import { EventEmitter } from 'events';
|
||||
import type { IExecuteFunctions, INodeExecutionData, IWorkflowDataProxyData } from 'n8n-workflow';
|
||||
import type {
|
||||
IExecuteFunctions,
|
||||
INodeExecutionData,
|
||||
ISupplyDataFunctions,
|
||||
IWorkflowDataProxyData,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
import { isObject } from './utils';
|
||||
import { ValidationError } from './ValidationError';
|
||||
@@ -19,7 +24,10 @@ export interface SandboxContext extends IWorkflowDataProxyData {
|
||||
|
||||
export const REQUIRED_N8N_ITEM_KEYS = new Set(['json', 'binary', 'pairedItem', 'error']);
|
||||
|
||||
export function getSandboxContext(this: IExecuteFunctions, index: number): SandboxContext {
|
||||
export function getSandboxContext(
|
||||
this: IExecuteFunctions | ISupplyDataFunctions,
|
||||
index: number,
|
||||
): SandboxContext {
|
||||
const helpers = {
|
||||
...this.helpers,
|
||||
httpRequestWithAuthentication: this.helpers.httpRequestWithAuthentication.bind(this),
|
||||
|
||||
Reference in New Issue
Block a user