Fix Insights.measure this handling
This commit is contained in:
parent
2e57f090e6
commit
bb41e9743f
1 changed files with 2 additions and 3 deletions
|
|
@ -29,10 +29,9 @@ export class Insights {
|
||||||
const targetFunction = descriptor.value;
|
const targetFunction = descriptor.value;
|
||||||
|
|
||||||
descriptor.value = function (...values: Array<any>) {
|
descriptor.value = function (...values: Array<any>) {
|
||||||
return Insights.measureFunction(key, () =>
|
return Insights.measureFunction(key, () => targetFunction.apply(this, values));
|
||||||
targetFunction.bind(target)(...values)
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
return descriptor;
|
return descriptor;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue