mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-21 11:49:59 +00:00
refactor: Add rule no-constant-binary-expression (no-changelog) (#7670)
https://eslint.org/docs/latest/rules/no-constant-binary-expression
This commit is contained in:
@@ -743,7 +743,7 @@ export class ClickUp implements INodeType {
|
||||
) {
|
||||
if (
|
||||
additionalFields.stepsStart === undefined ||
|
||||
!additionalFields.stepsEnd === undefined
|
||||
additionalFields.stepsEnd === undefined
|
||||
) {
|
||||
throw new NodeOperationError(
|
||||
this.getNode(),
|
||||
|
||||
@@ -96,7 +96,7 @@ export async function haloPSAApiRequest(
|
||||
return result;
|
||||
} catch (error) {
|
||||
const message = (error as JsonObject).message as string;
|
||||
if (method === 'DELETE' || 'GET' || ('UPDATE' && message)) {
|
||||
if (method === 'DELETE' || method === 'GET' || (method === 'UPDATE' && message)) {
|
||||
let newErrorMessage;
|
||||
if (message.includes('400')) {
|
||||
console.log(message);
|
||||
|
||||
@@ -235,7 +235,7 @@ export async function odooGet(
|
||||
password,
|
||||
mapOdooResources[resource] || resource,
|
||||
mapOperationToJSONRPC[operation],
|
||||
[+itemsID] || [],
|
||||
itemsID ? [+itemsID] : [],
|
||||
fieldsToReturn || [],
|
||||
],
|
||||
},
|
||||
@@ -326,7 +326,7 @@ export async function odooUpdate(
|
||||
password,
|
||||
mapOdooResources[resource] || resource,
|
||||
mapOperationToJSONRPC[operation],
|
||||
[+itemsID] || [],
|
||||
itemsID ? [+itemsID] : [],
|
||||
fieldsToUpdate,
|
||||
],
|
||||
},
|
||||
@@ -369,7 +369,7 @@ export async function odooDelete(
|
||||
password,
|
||||
mapOdooResources[resource] || resource,
|
||||
mapOperationToJSONRPC[operation],
|
||||
[+itemsID] || [],
|
||||
itemsID ? [+itemsID] : [],
|
||||
],
|
||||
},
|
||||
id: Math.floor(Math.random() * 100),
|
||||
|
||||
@@ -84,7 +84,7 @@ export function updateDisplayOptions(
|
||||
|
||||
export function processJsonInput<T>(jsonData: T, inputName?: string) {
|
||||
let values;
|
||||
const input = `'${inputName}' ` || '';
|
||||
const input = inputName ? `'${inputName}' ` : '';
|
||||
|
||||
if (typeof jsonData === 'string') {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user