mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-21 20:00:02 +00:00
n8n-3867-progressively-apply-prettier-to-all (#3873)
* 🔨 formatting nodes with prettier
This commit is contained in:
@@ -1,22 +1,16 @@
|
||||
import {
|
||||
IExecuteFunctions,
|
||||
} from 'n8n-core';
|
||||
import { IExecuteFunctions } from 'n8n-core';
|
||||
|
||||
import {
|
||||
IDataObject,
|
||||
INodeExecutionData,
|
||||
NodeOperationError,
|
||||
} from 'n8n-workflow';
|
||||
import { IDataObject, INodeExecutionData, NodeOperationError } from 'n8n-workflow';
|
||||
|
||||
import {
|
||||
apiRequest,
|
||||
} from '../../../transport';
|
||||
import { apiRequest } from '../../../transport';
|
||||
|
||||
|
||||
export async function updateTicket(this: IExecuteFunctions, index: number): Promise<INodeExecutionData[]> {
|
||||
export async function updateTicket(
|
||||
this: IExecuteFunctions,
|
||||
index: number,
|
||||
): Promise<INodeExecutionData[]> {
|
||||
const id = this.getNodeParameter('ticketId', index) as IDataObject;
|
||||
const { assetId, customerId, dueDate, issueType, status, subject, ticketType, contactId } = this.getNodeParameter('updateFields', index) as IDataObject;
|
||||
|
||||
const { assetId, customerId, dueDate, issueType, status, subject, ticketType, contactId } =
|
||||
this.getNodeParameter('updateFields', index) as IDataObject;
|
||||
|
||||
const qs = {} as IDataObject;
|
||||
const requestMethod = 'PUT';
|
||||
@@ -35,7 +29,9 @@ export async function updateTicket(this: IExecuteFunctions, index: number): Prom
|
||||
};
|
||||
|
||||
if (!Object.keys(body).length) {
|
||||
throw new NodeOperationError(this.getNode(), 'At least one update fields has to be defined', { itemIndex: index });
|
||||
throw new NodeOperationError(this.getNode(), 'At least one update fields has to be defined', {
|
||||
itemIndex: index,
|
||||
});
|
||||
}
|
||||
|
||||
let responseData;
|
||||
|
||||
Reference in New Issue
Block a user