chore: switch coding style to JS standard
[e-mobility-charging-stations-simulator.git] / src / exception / BaseError.ts
index 2163f6ee4d78cce456a220391f0c498783cfc34e..6b9ea70fd914de381f4bf90a82abd9778dc8c9fd 100644 (file)
@@ -1,14 +1,14 @@
 export class BaseError extends Error {
-  public constructor(message?: string) {
-    super(message);
-    this.name = new.target.name;
-    Object.setPrototypeOf(this, new.target.prototype);
+  public constructor (message?: string) {
+    super(message)
+    this.name = new.target.name
+    Object.setPrototypeOf(this, new.target.prototype)
     typeof Error.captureStackTrace === 'function'
       ? Error.captureStackTrace(this, this.constructor)
-      : this.createStack();
+      : this.createStack()
   }
 
-  private createStack(): void {
-    this.stack = new Error().stack;
+  private createStack (): void {
+    this.stack = new Error().stack
   }
 }