From eafbe424b93a7aa57850623d07df1a52f6699799 Mon Sep 17 00:00:00 2001 From: Jan Oberhauser Date: Wed, 18 Nov 2020 23:59:36 +0100 Subject: [PATCH] :bug: Fix small bug in HumanticAI-Node --- packages/nodes-base/nodes/HumanticAI/HumanticAi.node.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/nodes-base/nodes/HumanticAI/HumanticAi.node.ts b/packages/nodes-base/nodes/HumanticAI/HumanticAi.node.ts index b7996bc008..334a53ddb0 100644 --- a/packages/nodes-base/nodes/HumanticAI/HumanticAi.node.ts +++ b/packages/nodes-base/nodes/HumanticAI/HumanticAi.node.ts @@ -109,10 +109,14 @@ export class HumanticAi implements INodeType { }, }, ); - responseData = responseData.data; } else { responseData = await humanticAiApiRequest.call(this, 'GET', `/user-profile/create`, {}, qs); + } + + if (responseData.data !== undefined) { responseData = responseData.data; + } else { + delete responseData.usage_stats; } } if (operation === 'get') {