refactor: make storage init compliant with MikroORM 6
[e-mobility-charging-stations-simulator.git] / src / utils / Utils.ts
index 9d2b92fa4239856b0c064d062168dc5cb121a93d..2472bf617621b87ef3752cc6000447918aa25300 100644 (file)
@@ -14,7 +14,11 @@ import {
 } from 'date-fns'
 
 import { Constants } from './Constants.js'
-import { type TimestampedData, WebSocketCloseEventStatusString } from '../types/index.js'
+import {
+  type EmptyObject,
+  type TimestampedData,
+  WebSocketCloseEventStatusString
+} from '../types/index.js'
 
 export const logPrefix = (prefixString = ''): string => {
   return `${new Date().toLocaleString()}${prefixString}`
@@ -261,7 +265,7 @@ export const isObject = (value: unknown): value is object => {
   return value != null && typeof value === 'object' && !Array.isArray(value)
 }
 
-export const isEmptyObject = (object: object): object is Record<string, never> => {
+export const isEmptyObject = (object: object): object is EmptyObject => {
   if (object.constructor !== Object) {
     return false
   }