closeall logs use already-defined plural method

This commit is contained in:
Oliver Cordingley 2021-01-19 17:20:49 +00:00
parent 2f98550ee3
commit 33b300f2b3
No known key found for this signature in database
GPG Key ID: BDD85B6392EE03EA

View File

@ -12,6 +12,7 @@ const fs = require('fs');
const { join } = require('path'); const { join } = require('path');
const config = require(join(__dirname, '../../user/', require('../').config)); const config = require(join(__dirname, '../../user/', require('../').config));
const archive = require('../modules/archive'); const archive = require('../modules/archive');
const { plural } = require('../modules/utils');
// A slight modification to the 'close' command to allow multiple tickets to be closed at once // A slight modification to the 'close' command to allow multiple tickets to be closed at once
@ -207,7 +208,7 @@ module.exports = {
let embed = new MessageEmbed() let embed = new MessageEmbed()
.setColor(config.colour) .setColor(config.colour)
.setAuthor(message.author.username, message.author.displayAvatarURL()) .setAuthor(message.author.username, message.author.displayAvatarURL())
.setTitle(`${tickets.count} ticket${tickets.count > 1 ? 's' : ''} closed (${config.prefix}closeall)`) .setTitle(`${tickets.count} ${plural('ticket', tickets.count)} closed (${config.prefix}closeall)`)
.addField('Closed by', message.author, true) .addField('Closed by', message.author, true)
.setFooter(guild.name, guild.iconURL()) .setFooter(guild.name, guild.iconURL())
.setTimestamp(); .setTimestamp();