diff --git a/src/classes/scripts.ts b/src/classes/scripts.ts index e9e85f2227..5a34adebe9 100644 --- a/src/classes/scripts.ts +++ b/src/classes/scripts.ts @@ -471,7 +471,7 @@ export class Scripts { ); case ErrorCode.ParentJobCannotBeReplaced: return new Error( - `The parent job of job ${jobId} cannot be replaced. ${command}`, + `The parent job ${parentKey} cannot be replaced. ${command}`, ); default: return new Error(`Unknown code ${code} error for ${jobId}. ${command}`); diff --git a/tests/test_flow.ts b/tests/test_flow.ts index a4a70ec9b1..0da0b1e7f3 100644 --- a/tests/test_flow.ts +++ b/tests/test_flow.ts @@ -1665,7 +1665,7 @@ describe('flows', () => { }, ), ).to.be.rejectedWith( - `The parent job of job ${prefix}:${queueName}:wed cannot be replaced. addJob`, + `The parent job ${prefix}:${queueName}:wed cannot be replaced. addJob`, ); await flow.close();