From 92077f954d9f7a086f9adf0d1e7c1397ef7d567a Mon Sep 17 00:00:00 2001
From: clauspeterhuebner
Date: Tue, 10 Feb 2026 02:42:39 +0100
Subject: [PATCH] change check for commandClass
---
core/src/command/CommandFactory.ts | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/core/src/command/CommandFactory.ts b/core/src/command/CommandFactory.ts
index cc62681e9..d9acd1a0e 100644
--- a/core/src/command/CommandFactory.ts
+++ b/core/src/command/CommandFactory.ts
@@ -27,7 +27,7 @@ export class CommandFactory {
}
this.commands.set(name, commandClass);
if (methodLogger.isDebugEnabled()) {
- methodLogger.debug(`registerCommand() commands=${JSON.stringify(Array.from(this.commands.entries()))}`)
+ methodLogger.debug(`registerCommand() commands=${JSON.stringify(this.commands.entries())}`)
}
}
@@ -38,9 +38,9 @@ export class CommandFactory {
}
const CommandClass = this.commands.get(name);
if (methodLogger.isDebugEnabled()) {
- methodLogger.debug(`createCommand() name=${name} commandClass=${CommandClass ? JSON.stringify(CommandClass) : 'null'}`)
+ methodLogger.debug(`createCommand() name=${name} commandClass=${CommandClass ? CommandClass.name : 'null'}`)
}
- if (!CommandClass) {
+ if (CommandClass === undefined) {
const errmsg = `Command ${name} not found`;
methodLogger.error(errmsg);
throw new Error(errmsg);