mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
refactor: replace var usage with let/const (#7064)
This commit is contained in:
@@ -177,7 +177,7 @@ const profileMethodUnnamed = (target, key, descriptor) => {
|
||||
if (descriptor === undefined) {
|
||||
descriptor = Object.getOwnPropertyDescriptor(target, key);
|
||||
}
|
||||
var originalMethod = descriptor.value;
|
||||
const originalMethod = descriptor.value;
|
||||
|
||||
let className = "";
|
||||
if (target && target.constructor && target.constructor.name) {
|
||||
@@ -199,7 +199,7 @@ const profileStaticMethodUnnamed = (ctor, key, descriptor) => {
|
||||
if (descriptor === undefined) {
|
||||
descriptor = Object.getOwnPropertyDescriptor(ctor, key);
|
||||
}
|
||||
var originalMethod = descriptor.value;
|
||||
const originalMethod = descriptor.value;
|
||||
|
||||
let className = "";
|
||||
if (ctor && ctor.name) {
|
||||
@@ -222,7 +222,7 @@ function profileMethodNamed(name: string): MethodDecorator {
|
||||
if (descriptor === undefined) {
|
||||
descriptor = Object.getOwnPropertyDescriptor(target, key);
|
||||
}
|
||||
var originalMethod = descriptor.value;
|
||||
const originalMethod = descriptor.value;
|
||||
|
||||
//editing the descriptor/value parameter
|
||||
descriptor.value = profileFunctionFactory(originalMethod, name);
|
||||
|
||||
Reference in New Issue
Block a user