mirror of
https://github.com/toast-ts/Daggerbot-TS.git
synced 2024-11-17 08:20:58 -05:00
idk anymore
This commit is contained in:
parent
9b56952c4c
commit
8b6036e8f0
@ -80,7 +80,7 @@ export default async(client:TClient,Channel:string,Message:string,ServerName:str
|
|||||||
const serverIndicatorEmbed =(indicator:string)=>new client.embed().setTitle(`**${ServerName}** is now ${indicator}`).setColor(client.config.embedColorOrange).setTimestamp();
|
const serverIndicatorEmbed =(indicator:string)=>new client.embed().setTitle(`**${ServerName}** is now ${indicator}`).setColor(client.config.embedColorOrange).setTimestamp();
|
||||||
|
|
||||||
const serverLog = client.channels.resolve(client.config.mainServer.channels.fs_server_log) as Discord.TextChannel;
|
const serverLog = client.channels.resolve(client.config.mainServer.channels.fs_server_log) as Discord.TextChannel;
|
||||||
const playersOnServer = DSS.data.slots.players.filter(x=>x.isUsed);
|
const playersOnServer = DSS.data.slots?.players.filter(x=>x.isUsed);
|
||||||
const playersInCache = client.MPServerCache.players;
|
const playersInCache = client.MPServerCache.players;
|
||||||
playersOnServer.forEach(player=>playerData.push(`**${player.name} ${player.isAdmin ? '| admin' : ''}**\nFarming for ${client.formatPlayerUptime(player.uptime)}`));
|
playersOnServer.forEach(player=>playerData.push(`**${player.name} ${player.isAdmin ? '| admin' : ''}**\nFarming for ${client.formatPlayerUptime(player.uptime)}`));
|
||||||
|
|
||||||
|
@ -48,11 +48,10 @@ export default {
|
|||||||
if (error) return;
|
if (error) return;
|
||||||
if (typeof output === 'object') output = 'js\n'+util.formatWithOptions({depth: 1}, '%O', output)
|
if (typeof output === 'object') output = 'js\n'+util.formatWithOptions({depth: 1}, '%O', output)
|
||||||
else output = '\n' + String(output);
|
else output = '\n' + String(output);
|
||||||
|
[
|
||||||
[client.tokens.main,client.tokens.beta,client.tokens.toast,client.tokens.tae,client.tokens.octokit,client.tokens.webhook_url,client.tokens.webhook_url_test,client.tokens.mongodb_uri,client.tokens.mongodb_uri_dev].forEach((x)=>{
|
client.tokens.main,client.tokens.beta,client.tokens.toast,client.tokens.webhook_url,
|
||||||
const regexp = new RegExp(x as string,'g');
|
client.tokens.webhook_url_test,client.tokens.mongodb_uri,client.tokens.mongodb_uri_dev,client.tokens.octokit
|
||||||
output = output.replace(regexp, ':noblank: No token?');
|
].forEach(x=>output = output.replace(new RegExp(x as string,'g'),':noblank: No token?'));
|
||||||
})
|
|
||||||
const embed = new client.embed().setColor(client.config.embedColor).setTitle('__Eval__').addFields(
|
const embed = new client.embed().setColor(client.config.embedColor).setTitle('__Eval__').addFields(
|
||||||
{name: 'Input', value: `\`\`\`js\n${code.slice(0,1010)}\n\`\`\``},
|
{name: 'Input', value: `\`\`\`js\n${code.slice(0,1010)}\n\`\`\``},
|
||||||
{name: 'Output', value: `\`\`\`${removeUsername(output).slice(0,1016)}\n\`\`\``}
|
{name: 'Output', value: `\`\`\`${removeUsername(output).slice(0,1016)}\n\`\`\``}
|
||||||
|
1
src/typings/interfaces.d.ts
vendored
1
src/typings/interfaces.d.ts
vendored
@ -125,7 +125,6 @@ export interface Tokens {
|
|||||||
main: string
|
main: string
|
||||||
beta: string
|
beta: string
|
||||||
toast: string
|
toast: string
|
||||||
tae: string
|
|
||||||
octokit: string
|
octokit: string
|
||||||
webhook_url: string
|
webhook_url: string
|
||||||
webhook_url_test: string
|
webhook_url_test: string
|
||||||
|
Loading…
Reference in New Issue
Block a user