From 941b87e872d47b4490d48c4b557b3ec23184a24b Mon Sep 17 00:00:00 2001 From: Alessio Onori Date: Tue, 14 Mar 2023 16:47:39 +0100 Subject: [PATCH] Update start.ts --- src/actions/start.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/actions/start.ts b/src/actions/start.ts index 8c7b6f4..f9916fb 100644 --- a/src/actions/start.ts +++ b/src/actions/start.ts @@ -36,6 +36,9 @@ const _loadConfig = async (config: any): Promise =>{ export async function startAction(cmd): Promise { const cfg = await _loadConfig(cmd.config) + const logger = LoggerSingleton.getInstance(cfg.logLevel) + logger.info(`loaded ${cfg.targets.length} accounts`) + const server = express(); server.get('/healthcheck', async (req: express.Request, res: express.Response): Promise => { @@ -46,8 +49,6 @@ export async function startAction(cmd): Promise { res.end(await register.metrics()) }) server.listen(cfg.port); - - LoggerSingleton.setInstance(cfg.logLevel) const api = await new Client(cfg).connect() const chain = await api.rpc.system.chain()