This commit is contained in:
Joonas 2023-02-04 18:21:55 +02:00
parent 293e5988ad
commit 955d13bfed
12 changed files with 29 additions and 24 deletions

View File

@ -5,7 +5,7 @@ const command = {
mod: true,
run: async (client, msg, splitted) => {
if (!splitted[2]) {
client
await client
.say(msg.channelName, `${msg.displayName}, Supply an arg PoroSad`)
.catch((err) => console.log(err));

View File

@ -5,7 +5,7 @@ const command = {
mod: false,
run: async (client, msg, splitted) => {
if (splitted[2] === undefined) {
client.say(
await client.say(
msg.channelName,
`${msg.displayName}, supply your Last.FM username PoroSad`
);
@ -22,7 +22,7 @@ const command = {
.catch((err) => console.log(err));
if (data === undefined) {
client
await client
.say(msg.channelName, `${msg.displayName}, Invalid user PoroSad`)
.catch((err) => console.log(err));
return;

View File

@ -11,7 +11,7 @@ const command = {
.then((data) => data.hits[Math.floor(Math.random() * data.hits.length)])
.catch((err) => console.log(err));
client
await client
.say(
msg.channelName,
`${msg.displayName}, Hacker News: ${data.title} (Points: ${data.points}, Comments: ${data.num_comments}) Article: ${data.url} Comments: https://news.ycombinator.com/item?id=${data.objectID}`

View File

@ -6,18 +6,20 @@ const command = {
run: async (client, msg) => {
await client
.join(msg.senderUsername)
.then(() =>
client.say(
msg.channelName,
`${msg.displayName}, joined ${msg.senderUsername} BroBalt`
)
.then(
async () =>
await client.say(
msg.channelName,
`${msg.displayName}, joined ${msg.senderUsername} BroBalt`
)
)
.then(() => client.say(msg.senderUsername, "MrDestructoid"))
.catch(() =>
client.say(
msg.channelName,
`${msg.displayName}, the bot is probably in your chat, but can't speak because of phone number etc verification`
)
.catch(
async () =>
await client.say(
msg.channelName,
`${msg.displayName}, the bot is probably in your chat, but can't speak because of phone number etc verification`
)
);
},
};

View File

@ -5,7 +5,10 @@ const command = {
mod: false,
run: async (client, msg, splitted) => {
if (splitted[2] === undefined || splitted[3] === undefined) {
client.say(msg.channelName, `${msg.displayName}, supply 2 args PoroSad`);
await client.say(
msg.channelName,
`${msg.displayName}, supply 2 args PoroSad`
);
return;
}

View File

@ -61,7 +61,7 @@ const command = {
}
default: {
client
await client
.say(
msg.channelName,
`${msg.displayName}, supply an action (create or fetch)`

View File

@ -14,7 +14,7 @@ const command = {
.catch((err) => console.log(err));
if (!data) {
client
await client
.say(
msg.channelName,
`${msg.displayName}, nothing found or ivr api is down`
@ -24,7 +24,7 @@ const command = {
return;
}
client
await client
.say(
msg.channelName,
`${msg.displayName}, [${new Date(data.timestamp).toLocaleString()}] ${

View File

@ -26,7 +26,7 @@ const command = {
.then((res) => res.text())
.catch((err) => console.log(err));
client
await client
.say(msg.channelName, `${msg.displayName}, shortened URL: ${data}`)
.catch((err) => console.log(err));
},

View File

@ -5,7 +5,7 @@ const command = {
mod: false,
run: async (client, msg, splitted) => {
if (!splitted[2]) {
client.say(
await client.say(
msg.channelName,
`${msg.displayName}, please supply an URL PoroSad`
);
@ -30,7 +30,7 @@ const command = {
.then((res) => res.text())
.catch((err) => console.log(err));
client
await client
.say(msg.channelName, `${msg.displayName}, sketchified URL: ${data}`)
.catch((err) => console.log(err));
},

View File

@ -20,7 +20,7 @@ const command = {
.catch((err) => console.log(err));
if (!data) {
client
await client
.say(
msg.channelName,
`${msg.displayName}, invalid name or api's are down`

View File

@ -22,7 +22,7 @@ const command = {
.catch((err) => console.log(err));
if (data === undefined) {
client
await client
.say(msg.channelName, `${msg.displayName}, Invalid location PoroSad`)
.catch((err) => console.log(err));

View File

@ -5,7 +5,7 @@ const command = {
mod: false,
run: async (client, msg, splitted) => {
if (splitted[2] === undefined) {
client
await client
.say(msg.channelName, `${msg.displayName}, supply a search PoroSad`)
.catch((err) => console.log(err));
return;