mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 19:49:50 +02:00
feat: /debug and /help
This commit is contained in:
1 parent
91260aed2a
commit
c37b90caac
11 files changed
+110
-10
No files matched your search
@@ -27,7 +27,7 @@ export default async function getBlitzAccount(
|
||||
callback(players.data[0]);
|
||||
} else {
|
||||
// no exact match
|
||||
interaction.reply({
|
||||
await interaction.reply({
|
||||
embeds: [
|
||||
new EmbedBuilder()
|
||||
.setColor(NEGATIVE_COLOR)
|
||||
@@ -49,5 +49,7 @@ export default async function getBlitzAccount(
|
||||
),
|
||||
],
|
||||
});
|
||||
|
||||
console.log(`Account not found for ${name} in ${serverName} server.`);
|
||||
}
|
||||
}
|
||||
@@ -13,8 +13,8 @@ export default async function getBlitzStarsAccount(
|
||||
name: string,
|
||||
callback: (account: PlayerStatistics) => void,
|
||||
) {
|
||||
function notTracked() {
|
||||
interaction.reply({
|
||||
async function notTracked() {
|
||||
await interaction.reply({
|
||||
embeds: [
|
||||
new EmbedBuilder()
|
||||
.setTitle('No data to display')
|
||||
@@ -22,6 +22,8 @@ export default async function getBlitzStarsAccount(
|
||||
.setColor(NEGATIVE_COLOR),
|
||||
],
|
||||
});
|
||||
|
||||
console.log(`${name} is not tracked by BlitzStars.`);
|
||||
}
|
||||
|
||||
fetch(`https://www.blitzstars.com/api/top/player/${accountId}`)
|
||||
|
||||
@@ -28,7 +28,7 @@ export default async function getClan(
|
||||
callback(clans.data[0]);
|
||||
} else {
|
||||
// no exact match
|
||||
interaction.reply({
|
||||
await interaction.reply({
|
||||
embeds: [
|
||||
new EmbedBuilder()
|
||||
.setColor(NEGATIVE_COLOR)
|
||||
@@ -48,5 +48,7 @@ export default async function getClan(
|
||||
),
|
||||
],
|
||||
});
|
||||
|
||||
console.log(`Clan not found for ${name} in ${serverName} server.`);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user