mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
🐛 Fix circular references removal (#1901)
Circular references removed only for the request library error.
This commit is contained in:
@@ -52,7 +52,6 @@ abstract class NodeError extends Error {
|
||||
|
||||
constructor(node: INode, error: Error | JsonObject) {
|
||||
super();
|
||||
this.removeCircularRefs(error as JsonObject);
|
||||
this.name = this.constructor.name;
|
||||
this.cause = error;
|
||||
this.node = node;
|
||||
@@ -215,6 +214,9 @@ export class NodeApiError extends NodeError {
|
||||
{ message, description, httpCode, parseXml }: { message?: string, description?: string, httpCode?: string, parseXml?: boolean } = {},
|
||||
) {
|
||||
super(node, error);
|
||||
if (error.error) { // only for request library error
|
||||
this.removeCircularRefs(error.error as JsonObject);
|
||||
}
|
||||
if (message) {
|
||||
this.message = message;
|
||||
this.description = description;
|
||||
|
||||
Reference in New Issue
Block a user