リファクタリング (#4587)

* Use I cap

* Avoid _

* Use default value instead of optional boolean

* Bye useless variable

* Bye verbose try-catch
This commit is contained in:
Acid Chicken (硫酸鶏)
2019-04-14 17:18:17 +09:00
committed by syuilo
parent 97bff010a8
commit 054220db70
8 changed files with 17 additions and 37 deletions

View File

@ -56,20 +56,12 @@ function cpuUsage() {
// MEMORY(excl buffer + cache) STAT
async function usedMem() {
try {
const data = await sysUtils.mem();
return data.active;
} catch (error) {
throw error;
}
const data = await sysUtils.mem();
return data.active;
}
// TOTAL MEMORY STAT
async function totalMem() {
try {
const data = await sysUtils.mem();
return data.total;
} catch (error) {
throw error;
}
const data = await sysUtils.mem();
return data.total;
}