⚡ Remove non-null assertions for Db collections (#3111)
* 📘 Remove unions to `null` * ⚡ Track `Db` initialization state * 🔥 Remove non-null assertions * 👕 Remove lint exceptions * 🔥 Remove leftover assertion
This commit is contained in:
@@ -513,7 +513,7 @@ export class WorkflowRunner {
|
||||
reject(error);
|
||||
}
|
||||
|
||||
const executionDb = (await Db.collections.Execution!.findOne(
|
||||
const executionDb = (await Db.collections.Execution.findOne(
|
||||
executionId,
|
||||
)) as IExecutionFlattedDb;
|
||||
const fullExecutionData = ResponseHelper.unflattenExecutionData(executionDb);
|
||||
@@ -548,7 +548,7 @@ export class WorkflowRunner {
|
||||
(workflowDidSucceed && saveDataSuccessExecution === 'none') ||
|
||||
(!workflowDidSucceed && saveDataErrorExecution === 'none')
|
||||
) {
|
||||
await Db.collections.Execution!.delete(executionId);
|
||||
await Db.collections.Execution.delete(executionId);
|
||||
await BinaryDataManager.getInstance().markDataForDeletionByExecutionId(executionId);
|
||||
}
|
||||
// eslint-disable-next-line id-denylist
|
||||
|
||||
Reference in New Issue
Block a user