mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 12:44:07 -08:00
🐛 Fix sending none JSON data bug
This commit is contained in:
parent
af2ed46a68
commit
fd185671db
|
@ -697,12 +697,8 @@ export class HttpRequest implements INodeType {
|
|||
}
|
||||
}
|
||||
|
||||
try {
|
||||
// @ts-ignore
|
||||
requestOptions[optionData.name] = JSON.parse(tempValue as string);
|
||||
} catch (error) {
|
||||
throw new Error(`${optionData.name} must be a valid JSON`);
|
||||
}
|
||||
// @ts-ignore
|
||||
requestOptions[optionData.name] = tempValue;
|
||||
|
||||
// @ts-ignore
|
||||
if (typeof requestOptions[optionData.name] !== 'object' && options.bodyContentType !== 'raw') {
|
||||
|
|
Loading…
Reference in a new issue