fix: fix error handling default options definition
[e-mobility-charging-stations-simulator.git] / src / performance / storage / Storage.ts
index aee3ae9efbb5ca86b17a8a7ddf3fcd01b7b80684..bdf7acb1d43617bf177a19cba0a6cb1c0d8a04b5 100644 (file)
@@ -26,9 +26,12 @@ export abstract class Storage {
     type: StorageType,
     error: Error,
     table?: string,
-    params: HandleErrorParams<EmptyObject> = { throwError: false, consoleOut: false }
+    params: HandleErrorParams<EmptyObject> = {
+      throwError: false,
+      consoleOut: false
+    }
   ): void {
-    setDefaultErrorParams(params, { throwError: false, consoleOut: false })
+    params = setDefaultErrorParams(params, { throwError: false, consoleOut: false })
     const inTableOrCollectionStr = table != null && ` in table or collection '${table}'`
     logger.error(
       `${this.logPrefix} ${this.getDBNameFromStorageType(type)} error '${