From 4ac6c3b049efb080b758d1ff5e180336afdc931e Mon Sep 17 00:00:00 2001 From: Ralph Varjabedian <5989699+ralphv@users.noreply.github.com> Date: Wed, 25 Sep 2024 21:04:53 -0400 Subject: [PATCH] we don't need this active always --- src/GallifreyRulesEngine.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/GallifreyRulesEngine.ts b/src/GallifreyRulesEngine.ts index 05c9da5..37edee8 100644 --- a/src/GallifreyRulesEngine.ts +++ b/src/GallifreyRulesEngine.ts @@ -57,6 +57,7 @@ import { loadAll } from 'js-yaml'; import { WithModuleNameType } from './base-interfaces/ModuleInterface'; import LoggerInterface from './interfaces/Providers/LoggerInterface'; import ConsoleLoggerProvider from './modules/ConsoleLoggerProvider'; +import { isMainThread } from 'worker_threads'; export class GallifreyRulesEngine { private readonly schemaLoader: SchemaLoader; @@ -69,7 +70,9 @@ export class GallifreyRulesEngine { private readonly asyncActions: AsyncActionConfigType[] = []; static { - GallifreyRulesEngine.banner(); + if (isMainThread) { + GallifreyRulesEngine.banner(); + } } constructor() {