diff --git a/tns-core-modules/utils/types.ts b/tns-core-modules/utils/types.ts index 84e0bacde..53ccc87d8 100644 --- a/tns-core-modules/utils/types.ts +++ b/tns-core-modules/utils/types.ts @@ -43,7 +43,7 @@ export function verifyCallback(value: any) { } var classInfosMap = new Map(); -var funcNameRegex = /function (.{1,})\(/; +var funcNameRegex = /function ([_a-zA-Z0-9]{1,})\(/; export function getClass(object: Object): string { return getClassInfo(object).name; } @@ -113,4 +113,4 @@ export class ClassInfo { export function toUIString(obj): string { return isNullOrUndefined(obj) ? "" : obj + ""; -} \ No newline at end of file +}