mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-24 04:04:06 -08:00
fix(HTTP Request Node): Fix typos in JSON validation error message (no-changelog) (#11197)
Co-authored-by: Jonathan Bennetts <jonathan.bennetts@gmail.com>
This commit is contained in:
parent
eb2d1ca357
commit
9431e3029c
|
@ -180,7 +180,7 @@ export class MessageEventBusDestinationWebhook
|
||||||
try {
|
try {
|
||||||
JSON.parse(this.jsonQuery);
|
JSON.parse(this.jsonQuery);
|
||||||
} catch {
|
} catch {
|
||||||
this.logger.error('JSON parameter need to be an valid JSON');
|
this.logger.error('JSON parameter needs to be valid JSON');
|
||||||
}
|
}
|
||||||
this.axiosRequestOptions.params = jsonParse(this.jsonQuery);
|
this.axiosRequestOptions.params = jsonParse(this.jsonQuery);
|
||||||
}
|
}
|
||||||
|
@ -198,7 +198,7 @@ export class MessageEventBusDestinationWebhook
|
||||||
try {
|
try {
|
||||||
JSON.parse(this.jsonHeaders);
|
JSON.parse(this.jsonHeaders);
|
||||||
} catch {
|
} catch {
|
||||||
this.logger.error('JSON parameter need to be an valid JSON');
|
this.logger.error('JSON parameter needs to be valid JSON');
|
||||||
}
|
}
|
||||||
this.axiosRequestOptions.headers = jsonParse(this.jsonHeaders);
|
this.axiosRequestOptions.headers = jsonParse(this.jsonHeaders);
|
||||||
}
|
}
|
||||||
|
|
|
@ -340,7 +340,7 @@ export class HttpRequestV3 implements INodeType {
|
||||||
} catch {
|
} catch {
|
||||||
throw new NodeOperationError(
|
throw new NodeOperationError(
|
||||||
this.getNode(),
|
this.getNode(),
|
||||||
'JSON parameter need to be an valid JSON',
|
'JSON parameter needs to be valid JSON',
|
||||||
{
|
{
|
||||||
itemIndex,
|
itemIndex,
|
||||||
},
|
},
|
||||||
|
@ -404,13 +404,9 @@ export class HttpRequestV3 implements INodeType {
|
||||||
try {
|
try {
|
||||||
JSON.parse(jsonQueryParameter);
|
JSON.parse(jsonQueryParameter);
|
||||||
} catch {
|
} catch {
|
||||||
throw new NodeOperationError(
|
throw new NodeOperationError(this.getNode(), 'JSON parameter needs to be valid JSON', {
|
||||||
this.getNode(),
|
itemIndex,
|
||||||
'JSON parameter need to be an valid JSON',
|
});
|
||||||
{
|
|
||||||
itemIndex,
|
|
||||||
},
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
requestOptions.qs = jsonParse(jsonQueryParameter);
|
requestOptions.qs = jsonParse(jsonQueryParameter);
|
||||||
|
@ -430,13 +426,9 @@ export class HttpRequestV3 implements INodeType {
|
||||||
try {
|
try {
|
||||||
JSON.parse(jsonHeadersParameter);
|
JSON.parse(jsonHeadersParameter);
|
||||||
} catch {
|
} catch {
|
||||||
throw new NodeOperationError(
|
throw new NodeOperationError(this.getNode(), 'JSON parameter needs to be valid JSON', {
|
||||||
this.getNode(),
|
itemIndex,
|
||||||
'JSON parameter need to be an valid JSON',
|
});
|
||||||
{
|
|
||||||
itemIndex,
|
|
||||||
},
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
additionalHeaders = jsonParse(jsonHeadersParameter);
|
additionalHeaders = jsonParse(jsonHeadersParameter);
|
||||||
|
|
Loading…
Reference in a new issue