mirror of
https://github.com/BluemediaDev/muse.git
synced 2025-06-27 17:22:42 +02:00
Add better responses
This commit is contained in:
parent
1a1bdfd674
commit
15d4e251f2
17 changed files with 103 additions and 63 deletions
|
@ -2,6 +2,7 @@ import {Message} from 'discord.js';
|
|||
import {TYPES} from '../types';
|
||||
import {inject, injectable} from 'inversify';
|
||||
import QueueManager from '../managers/queue';
|
||||
import errorMsg from '../utils/error-msg';
|
||||
import Command from '.';
|
||||
|
||||
@injectable()
|
||||
|
@ -21,12 +22,13 @@ export default class implements Command {
|
|||
const queue = this.queueManager.get(msg.guild!.id).get();
|
||||
|
||||
if (queue.length <= 2) {
|
||||
await msg.channel.send('error: not enough songs to shuffle');
|
||||
await msg.channel.send(errorMsg('not enough songs to shuffle'));
|
||||
return;
|
||||
}
|
||||
|
||||
this.queueManager.get(msg.guild!.id).shuffle();
|
||||
|
||||
await msg.channel.send('`' + JSON.stringify(this.queueManager.get(msg.guild!.id).get().slice(0, 10)) + '`');
|
||||
// TODO: better response
|
||||
await msg.channel.send('shuffled');
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue