From bb41e9743f94c29c01db28474f457ecddd545898 Mon Sep 17 00:00:00 2001 From: schmelczerandras Date: Sun, 27 Sep 2020 16:11:30 +0200 Subject: [PATCH] Fix Insights.measure this handling --- src/graphics/rendering/insights.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/graphics/rendering/insights.ts b/src/graphics/rendering/insights.ts index 552b0b6..315bb59 100644 --- a/src/graphics/rendering/insights.ts +++ b/src/graphics/rendering/insights.ts @@ -29,10 +29,9 @@ export class Insights { const targetFunction = descriptor.value; descriptor.value = function (...values: Array) { - return Insights.measureFunction(key, () => - targetFunction.bind(target)(...values) - ); + return Insights.measureFunction(key, () => targetFunction.apply(this, values)); }; + return descriptor; }; }