Remove not used code

This commit is contained in:
Jan Oberhauser 2021-10-21 18:04:08 -05:00
parent bb05f8113d
commit 0b56db5617

View file

@ -54,7 +54,6 @@ import {
import { import {
ICredentialsDecrypted, ICredentialsDecrypted,
ICredentialsEncrypted,
ICredentialType, ICredentialType,
IDataObject, IDataObject,
INodeCredentials, INodeCredentials,
@ -67,12 +66,12 @@ import {
INodeVersionedType, INodeVersionedType,
ITelemetrySettings, ITelemetrySettings,
IWorkflowBase, IWorkflowBase,
IWorkflowCredentials,
LoggerProxy, LoggerProxy,
NodeCredentialTestRequest, NodeCredentialTestRequest,
NodeCredentialTestResult, NodeCredentialTestResult,
NodeHelpers, NodeHelpers,
Workflow, Workflow,
ICredentialsEncrypted,
WorkflowExecuteMode, WorkflowExecuteMode,
} from 'n8n-workflow'; } from 'n8n-workflow';
@ -1820,12 +1819,6 @@ class App {
return ResponseHelper.sendErrorResponse(res, errorResponse); return ResponseHelper.sendErrorResponse(res, errorResponse);
} }
// Decrypt the currently saved credentials
const workflowCredentials: IWorkflowCredentials = {
[result.type]: {
[result.id.toString()]: result as ICredentialsEncrypted,
},
};
const mode: WorkflowExecuteMode = 'internal'; const mode: WorkflowExecuteMode = 'internal';
const credentialsHelper = new CredentialsHelper(encryptionKey); const credentialsHelper = new CredentialsHelper(encryptionKey);
const decryptedDataOriginal = await credentialsHelper.getDecrypted( const decryptedDataOriginal = await credentialsHelper.getDecrypted(
@ -2044,13 +2037,6 @@ class App {
return ResponseHelper.sendErrorResponse(res, errorResponse); return ResponseHelper.sendErrorResponse(res, errorResponse);
} }
// Decrypt the currently saved credentials
const workflowCredentials: IWorkflowCredentials = {
[result.type]: {
[result.id.toString()]: result as ICredentialsEncrypted,
},
};
const mode: WorkflowExecuteMode = 'internal'; const mode: WorkflowExecuteMode = 'internal';
const credentialsHelper = new CredentialsHelper(encryptionKey); const credentialsHelper = new CredentialsHelper(encryptionKey);
const decryptedDataOriginal = await credentialsHelper.getDecrypted( const decryptedDataOriginal = await credentialsHelper.getDecrypted(