File tree Expand file tree Collapse file tree 2 files changed +2
-7
lines changed
Expand file tree Collapse file tree 2 files changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -23,11 +23,6 @@ export async function run(interaction: ChatInputCommandInteraction) {
2323 const members = guilds . map ( guild => guild . memberCount ) . reduce ( ( a , b ) => a + b ) ;
2424 const shards = client . shard ?. count ;
2525 const avatar = user . displayAvatarURL ( ) ;
26- const allMembers = await Promise . all ( guilds . map ( guild => guild . members . fetch ( ) ) ) ;
27- const uniqueIDs = new Set < string > ( ) ;
28-
29- for ( const col of allMembers ) for ( const member of col . values ( ) ) uniqueIDs . add ( member . id ) ;
30- const uniqueUsers = Array . from ( uniqueIDs ) . length ;
3126
3227 const embed = new EmbedBuilder ( )
3328 . setAuthor ( {
@@ -42,7 +37,7 @@ export async function run(interaction: ChatInputCommandInteraction) {
4237 name : "📃 • General" ,
4338 value : [
4439 `Version **${ version } **, *Antei*` ,
45- `**${ members } ** ${ pluralOrNot ( "member" , members ) } • **${ uniqueUsers } ** ${ pluralOrNot ( "unique user" , uniqueUsers ) } • ** ${ guilds . size } ** ${ pluralOrNot (
40+ `**${ members } ** ${ pluralOrNot ( "member" , members ) } • **${ guilds . size } ** ${ pluralOrNot (
4641 "guild" ,
4742 guilds . size ,
4843 ) } ${ ! shards ? "" : ` • **${ shards } ** ${ pluralOrNot ( "shard" , shards ) } ` } `,
Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ const listModQuery = database.query(
3636) ;
3737const getIdQuery = database . query ( "SELECT * FROM moderation WHERE guild = $1 AND id = $2;" ) ;
3838const getLastIdQuery = database . query (
39- "SELECT CAST(id AS int) AS id FROM moderation ORDER BY id DESC LIMIT 1;" ,
39+ "SELECT CAST(id AS int) AS id FROM moderation WHERE guild = ? ORDER BY id DESC LIMIT 1;" ,
4040) ;
4141const editQuery = database . query (
4242 "UPDATE moderation SET reason = ?3, expiresAt = ?4 WHERE guild = ?1 AND id = ?2;" ,
You can’t perform that action at this time.
0 commit comments