1
0
mirror of https://github.com/toast-ts/Daggerbot-TS.git synced 2024-12-27 00:05:39 -05:00

*dies of cringe*

This commit is contained in:
toast-ts 2024-01-11 16:52:20 +11:00
parent 455b9a2f80
commit b7a43c04a6

View File

@ -10,9 +10,9 @@ import {requestServerData, mpModuleDisabled, refreshTimerSecs, playtimeStat} fro
async function fetchData(client:TClient, interaction:Discord.ChatInputCommandInteraction, serverName:string):Promise<FSData|Discord.InteractionResponse> {
const db = await client.MPServer.findInCache();
const {dss} = await requestServerData(client, db.find(x=>x.serverName === serverName));
if (!dss) return interaction.reply('Ran into a '+RanIntoHumor+' while trying to retrieve server data, please try again later.');
return dss as FSData;
const data = await requestServerData(client, db.find(x=>x.serverName === serverName));
if (!data) return interaction.reply('Ran into a '+RanIntoHumor+' while trying to retrieve server data, please try again later.');
return data.dss as FSData;
}
const logPrefix = 'MPDB';