Skip to content

Commit

Permalink
"the created msg will be shown after setting it in the db"
Browse files Browse the repository at this point in the history
  • Loading branch information
Josee9988 committed Jun 21, 2021
1 parent b383325 commit 452ce9a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/commands/commands-controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,12 @@ export default class CommandsController {
*/
private async setSendMsg(message: Message, msgToBeSet: string[]): Promise<void> {
let msg = "";
for (const word of msgToBeSet) msg += word + "";
for (const word of msgToBeSet) msg += word + " ";
if (!checkIfUserIsAdmin(message)) return;
const server = await this.databaseController.findByServerId(message.guild.id);
if (server.channelId) {
await this.databaseController.setSendMsg(message.guild.id, msg);
await message.channel.send("Your message is set :)");
await message.channel.send("Your message is now: " + msg);
} else { // no channel specified
await message.channel.send(":interrobang:Please specify a channel first with `!dimg channel nameOfYourChannel`");
}
Expand Down

0 comments on commit 452ce9a

Please sign in to comment.