mirror of
https://github.com/BreizhHardware/memoizee.git
synced 2026-03-18 21:40:27 +01:00
style: prettier
This commit is contained in:
10
profile.js
10
profile.js
@@ -34,12 +34,8 @@ Object.defineProperty(
|
|||||||
if (!stats[id]) stats[id] = { initial: 0, cached: 0 };
|
if (!stats[id]) stats[id] = { initial: 0, cached: 0 };
|
||||||
data = stats[id];
|
data = stats[id];
|
||||||
|
|
||||||
conf.on("set", function () {
|
conf.on("set", function () { ++data.initial; });
|
||||||
++data.initial;
|
conf.on("get", function () { ++data.cached; });
|
||||||
});
|
|
||||||
conf.on("get", function () {
|
|
||||||
++data.cached;
|
|
||||||
});
|
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -53,7 +49,7 @@ exports.log = function () {
|
|||||||
if (!initialCount && !cachedCount) {
|
if (!initialCount && !cachedCount) {
|
||||||
return "0.00";
|
return "0.00";
|
||||||
}
|
}
|
||||||
return (cachedCount / (initialCount + cachedCount) * 100).toFixed(2);
|
return ((cachedCount / (initialCount + cachedCount)) * 100).toFixed(2);
|
||||||
};
|
};
|
||||||
|
|
||||||
log = "------------------------------------------------------------\n";
|
log = "------------------------------------------------------------\n";
|
||||||
|
|||||||
Reference in New Issue
Block a user