Skip to content

Commit c35f96b

Browse files
Techbot121Meta Construct
authored andcommitted
small fix
1 parent 123ac94 commit c35f96b

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

app/services/Motd.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -277,6 +277,7 @@ export class Motd extends Service {
277277
const wordList = motd
278278
.split(" ")
279279
.filter(w => w.length <= 22 && !filter.includes(w.toLowerCase()));
280+
if (wordList.length === 0) return;
280281
const word = wordList[(Math.random() * wordList?.length) | 0];
281282
nick = word.charAt(0).toUpperCase() + word.slice(1);
282283
return await this.bot.setNickname(nick, "Random Motd name");

app/services/discord/modules/logging.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ export default (bot: DiscordBot): void => {
205205
iconURL: user?.avatarURL() ?? user?.user.avatarURL() ?? undefined,
206206
})
207207
.setFooter({
208-
text: `${actionName}${
208+
text: `${actionName ?? entry.action}${
209209
actionName !== entry.targetType + entry.actionType
210210
? ` (${entry.targetType} ${entry.actionType})`
211211
: ""

0 commit comments

Comments
 (0)