mirror of
https://github.com/toast-ts/Daggerbot-TS.git
synced 2024-11-18 00:31:00 -05:00
This commit is contained in:
parent
aca2d449c6
commit
2beead7022
@ -77,6 +77,9 @@ export default class MP {
|
|||||||
if (!DSS) return console.log('Endpoint failed - details');
|
if (!DSS) return console.log('Endpoint failed - details');
|
||||||
const db = await client.MPServer.findInCache();
|
const db = await client.MPServer.findInCache();
|
||||||
const server = db.find(x=>x.serverName === choiceSelector);
|
const server = db.find(x=>x.serverName === choiceSelector);
|
||||||
|
if (!server) return;
|
||||||
|
// Shouldn't throw "Cannot read properties of undefined" error now,
|
||||||
|
// but I hate people finding new ways to cause the bot to have a minor aneurysm
|
||||||
|
|
||||||
const dEmbed = new client.embed().setColor(client.config.embedColor).setAuthor({name: 'Crossplay server'}).setDescription(MessageTool.concatMessage(
|
const dEmbed = new client.embed().setColor(client.config.embedColor).setAuthor({name: 'Crossplay server'}).setDescription(MessageTool.concatMessage(
|
||||||
`**Name:** \`${DSS.server?.name.length > 0 ? DSS.server.name : '\u200b'}\``,
|
`**Name:** \`${DSS.server?.name.length > 0 ? DSS.server.name : '\u200b'}\``,
|
||||||
|
Loading…
Reference in New Issue
Block a user