diff --git a/src/ts/@overflow/commons/invoke/ServiceInvoker.ts b/src/ts/@overflow/commons/invoke/ServiceInvoker.ts index b232c68..d915448 100644 --- a/src/ts/@overflow/commons/invoke/ServiceInvoker.ts +++ b/src/ts/@overflow/commons/invoke/ServiceInvoker.ts @@ -7,7 +7,11 @@ export class ServiceInvoker { } public invoke(className: string, methodName: string, params?: any): void { - let classObj: Object = this.configMap[className]; + let classObj: Object = this.configMap.get(className); + if (classObj === null) { + console.log('Error: Cannot find the class. [' + className + ']'); + return; + } if (!classObj.hasOwnProperty(methodName)) { console.log('Error: Cannot find the method. [' + methodName + ']'); return;