aboutsummaryrefslogtreecommitdiff
path: root/src/tasks/memberCount.ts
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-06-17 20:03:05 -0400
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-06-17 20:03:05 -0400
commite1c613829950a534d9f45c00a033b83575be3b3c (patch)
tree2de1e5231217211ae4087c46cc74dc46c584507a /src/tasks/memberCount.ts
parent0e87bbd3940d89defcb04926587b35c8f4d1947f (diff)
downloadtanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.tar.gz
tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.tar.bz2
tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.zip
remove global client variable
Diffstat (limited to 'src/tasks/memberCount.ts')
-rw-r--r--src/tasks/memberCount.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/tasks/memberCount.ts b/src/tasks/memberCount.ts
index fa51080..ea422fa 100644
--- a/src/tasks/memberCount.ts
+++ b/src/tasks/memberCount.ts
@@ -10,10 +10,10 @@ export default class MemberCountTask extends BushTask {
}
public override async exec() {
- if (!client.config.isProduction) return;
+ if (!this.client.config.isProduction) return;
const res = await Promise.allSettled(
- client.guilds.cache
+ this.client.guilds.cache
.filter((g) => g.memberCount >= 100)
.map((g) => MemberCount.create({ guildId: g.id, memberCount: g.memberCount }))
);
@@ -22,7 +22,7 @@ export default class MemberCountTask extends BushTask {
.filter((r) => r.status === 'rejected')
.forEach((r) => {
assert(r.status === 'rejected');
- void client.console.error('memberCount', r.status);
+ void this.client.console.error('memberCount', r.status);
});
}
}