X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Fcharging-station%2Fui-server%2FUIServerFactory.ts;h=905ce66d5325fc7bca9424d6f313de5cec089588;hb=be34dba565184fc320ac7621688ee5a35659e712;hp=2e5245329b9b70485a8796f92bd2b661124c602d;hpb=976d11ec6d2d38a5a82440de79f059638e28cdbd;p=e-mobility-charging-stations-simulator.git diff --git a/src/charging-station/ui-server/UIServerFactory.ts b/src/charging-station/ui-server/UIServerFactory.ts index 2e524532..905ce66d 100644 --- a/src/charging-station/ui-server/UIServerFactory.ts +++ b/src/charging-station/ui-server/UIServerFactory.ts @@ -1,14 +1,10 @@ import chalk from 'chalk'; -import type { UIServerConfiguration } from '../../types/ConfigurationData'; -import { ApplicationProtocol } from '../../types/UIProtocol'; -import Configuration from '../../utils/Configuration'; -import type { AbstractUIServer } from './AbstractUIServer'; -import { UIServiceUtils } from './ui-services/UIServiceUtils'; -import UIHttpServer from './UIHttpServer'; -import UIWebSocketServer from './UIWebSocketServer'; +import { ApplicationProtocol, type UIServerConfiguration } from '../../types'; +import { Configuration } from '../../utils'; +import { type AbstractUIServer, UIHttpServer, UIServerUtils, UIWebSocketServer } from '../internal'; -export default class UIServerFactory { +export class UIServerFactory { private constructor() { // This is intentional } @@ -16,9 +12,9 @@ export default class UIServerFactory { public static getUIServerImplementation( uiServerConfiguration?: UIServerConfiguration ): AbstractUIServer | null { - if (UIServiceUtils.isLoopback(uiServerConfiguration.options?.host) === false) { + if (UIServerUtils.isLoopback(uiServerConfiguration.options?.host) === false) { console.warn( - chalk.magenta( + chalk.yellow( 'Loopback address not detected in UI server configuration. This is not recommended.' ) );