diff --git a/Xiao.js b/Xiao.js index 03bb542b..b35873f2 100644 --- a/Xiao.js +++ b/Xiao.js @@ -2,6 +2,7 @@ require('dotenv').config(); const { XIAO_TOKEN, OWNERS, XIAO_PREFIX, INVITE } = process.env; const { mkdir } = require('fs/promises'); const path = require('path'); +const mathjs = require('mathjs'); const { GatewayIntentBits, Partials, AllowedMentionsTypes, PermissionFlagsBits, EmbedBuilder } = require('discord.js'); const Client = require('./structures/Client'); const client = new Client({ @@ -235,6 +236,12 @@ client.on('ready', async () => { client.logger.error(`[TIMEZONES] Failed to set timezones\n${err.stack}`); } + // Add bananas unit to mathjs + math.createUnit('banana', { + definition: '0.178 meters', + aliases: ['bananas'] + }); + // Fetch adult site list try { await client.fetchAdultSiteList(); diff --git a/commands/edit-number/units.js b/commands/edit-number/units.js index 0a0d679d..763749d5 100644 --- a/commands/edit-number/units.js +++ b/commands/edit-number/units.js @@ -2,10 +2,6 @@ const Command = require('../../framework/Command'); const math = require('mathjs'); const { stripIndents } = require('common-tags'); const { formatNumber } = require('../../util/Util'); -math.createUnit('banana', { - definition: '0.178 meters', - aliases: ['bananas'] -}); module.exports = class UnitsCommand extends Command { constructor(client) {