mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
feat: Do not show errors not processed by n8n (no-changelog) (#9598)
Co-authored-by: कारतोफ्फेलस्क्रिप्ट™ <aditya@netroy.in>
This commit is contained in:
@@ -335,7 +335,7 @@ export class MySqlV1 implements INodeType {
|
||||
[] as INodeExecutionData[],
|
||||
);
|
||||
} catch (error) {
|
||||
if (this.continueOnFail()) {
|
||||
if (this.continueOnFail(error)) {
|
||||
returnItems = this.helpers.returnJsonArray({ error: error.message });
|
||||
} else {
|
||||
await connection.end();
|
||||
@@ -372,7 +372,7 @@ export class MySqlV1 implements INodeType {
|
||||
|
||||
returnItems = this.helpers.returnJsonArray(queryResult[0] as unknown as IDataObject);
|
||||
} catch (error) {
|
||||
if (this.continueOnFail()) {
|
||||
if (this.continueOnFail(error)) {
|
||||
returnItems = this.helpers.returnJsonArray({ error: error.message });
|
||||
} else {
|
||||
await connection.end();
|
||||
@@ -407,7 +407,7 @@ export class MySqlV1 implements INodeType {
|
||||
queryResult.map((result) => result[0]) as unknown as IDataObject[],
|
||||
);
|
||||
} catch (error) {
|
||||
if (this.continueOnFail()) {
|
||||
if (this.continueOnFail(error)) {
|
||||
returnItems = this.helpers.returnJsonArray({ error: error.message });
|
||||
} else {
|
||||
await connection.end();
|
||||
|
||||
@@ -264,7 +264,7 @@ export function configureQueryRunner(
|
||||
} catch (err) {
|
||||
const error = parseMySqlError.call(this, err, 0, formatedQueries);
|
||||
|
||||
if (!this.continueOnFail()) throw error;
|
||||
if (!this.continueOnFail(err)) throw error;
|
||||
returnData.push({ json: { message: error.message, error: { ...error } } });
|
||||
}
|
||||
} else {
|
||||
@@ -302,7 +302,7 @@ export function configureQueryRunner(
|
||||
} catch (err) {
|
||||
const error = parseMySqlError.call(this, err, index, [formatedQuery]);
|
||||
|
||||
if (!this.continueOnFail()) {
|
||||
if (!this.continueOnFail(err)) {
|
||||
connection.release();
|
||||
throw error;
|
||||
}
|
||||
@@ -352,7 +352,7 @@ export function configureQueryRunner(
|
||||
connection.release();
|
||||
}
|
||||
|
||||
if (!this.continueOnFail()) throw error;
|
||||
if (!this.continueOnFail(err)) throw error;
|
||||
returnData.push(prepareErrorItem(queries[index], error as Error, index));
|
||||
|
||||
// Return here because we already rolled back the transaction
|
||||
|
||||
Reference in New Issue
Block a user