diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-06-17 20:03:05 -0400 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-06-17 20:03:05 -0400 |
commit | e1c613829950a534d9f45c00a033b83575be3b3c (patch) | |
tree | 2de1e5231217211ae4087c46cc74dc46c584507a /src/tasks/cpuUsage.ts | |
parent | 0e87bbd3940d89defcb04926587b35c8f4d1947f (diff) | |
download | tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.tar.gz tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.tar.bz2 tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.zip |
remove global client variable
Diffstat (limited to 'src/tasks/cpuUsage.ts')
-rw-r--r-- | src/tasks/cpuUsage.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/tasks/cpuUsage.ts b/src/tasks/cpuUsage.ts index 6ce6671..f456c31 100644 --- a/src/tasks/cpuUsage.ts +++ b/src/tasks/cpuUsage.ts @@ -1,5 +1,5 @@ import { BushTask, Time } from '#lib'; -import { cpu } from 'node-os-utils'; +import osu from 'node-os-utils'; export default class CpuUsageTask extends BushTask { public constructor() { @@ -10,7 +10,7 @@ export default class CpuUsageTask extends BushTask { } public async exec() { - const cpuStats = await cpu.usage(client.stats.cpu === undefined ? 100 * Time.Millisecond : Time.Minute); - client.stats.cpu = cpuStats; + const cpuStats = await osu.cpu.usage(this.client.stats.cpu === undefined ? 100 * Time.Millisecond : Time.Minute); + this.client.stats.cpu = cpuStats; } } |