From 5906bfe895097b8b06e87ca76a69749d55847734 Mon Sep 17 00:00:00 2001 From: Histmy Date: Sun, 20 Feb 2022 12:56:51 +0100 Subject: [PATCH] pomoc3 will no longer have random args --- src/app.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/app.ts b/src/app.ts index b9419b5..868374c 100644 --- a/src/app.ts +++ b/src/app.ts @@ -47,8 +47,8 @@ const runEvent = (name: string, args: any[]) => { }; const getTenParam = (fn: RunFunkce): string | undefined => fn.toString() - .match(/(?:function\s.*?)?\(([^)]*)\)/)![1] - .split(",")[1] + .match(/(?:function\s.*?)?\(([^)]*)\)|\w+ =>/)![1] + ?.split(",")[1] ?.trim(); const fnToArg = (fn: RunFunkce | string) => {