diff options
| author | Max Isom <[email protected]> | 2020-03-18 12:40:31 -0500 |
|---|---|---|
| committer | Max Isom <[email protected]> | 2020-03-18 12:40:31 -0500 |
| commit | 11246812a6e5da88750bf4b6ded159dd4020a3d3 (patch) | |
| tree | a12d6bdd142c8e67b035bab4720cea64d444cd5c /src/commands/queue.ts | |
| parent | 7844e80991d784eed107dd9a661dd5257ae49675 (diff) | |
| download | muse-11246812a6e5da88750bf4b6ded159dd4020a3d3.tar.xz muse-11246812a6e5da88750bf4b6ded159dd4020a3d3.zip | |
Don't allow seeking past end of song
Diffstat (limited to 'src/commands/queue.ts')
| -rw-r--r-- | src/commands/queue.ts | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/commands/queue.ts b/src/commands/queue.ts index e77cbcb..a194729 100644 --- a/src/commands/queue.ts +++ b/src/commands/queue.ts @@ -18,8 +18,10 @@ export default class implements Command { } public async execute(msg: Message, _: string []): Promise<void> { - const queue = this.queueManager.get(msg.guild!.id).get(); + const queue = this.queueManager.get(msg.guild!.id); - await msg.channel.send('`' + JSON.stringify(queue.slice(0, 10)) + '`'); + await msg.channel.send('`' + JSON.stringify(queue.getCurrent()) + '`'); + + await msg.channel.send('`' + JSON.stringify(queue.get().slice(0, 10)) + '`'); } } |
