Skip to content

Commit f80c166

Browse files
committed
fix: improve error message formatting and enhance quiz command cleanup
1 parent 7d4a064 commit f80c166

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

src/components/events/message.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,9 +171,10 @@ export default async function (msg: Message) {
171171
const logFn = status === 500 ? log.error : log.warn;
172172
logFn(key, statusMessages[status], { status, headers });
173173
const text = `
174-
\`Status ${status}:\`
174+
\`${statusMessages[status]}\`
175175
176-
Error Fetching to ${key} provider got ${statusMessages[status]}
176+
Error fetching data for "${key}" command the
177+
provider returned a ${status} status code.
177178
`;
178179
await msg.reply(text);
179180
return;

src/components/events/quiz.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ export default async function (
4141
await Promise.all([
4242
msg.reply(done[Math.floor(Math.random() * done.length)]),
4343
setQuizAttemptAnswered(msg, quoted),
44+
quoted.delete(true, true),
4445
]);
4546
return true;
4647
}

0 commit comments

Comments
 (0)