aboutsummaryrefslogtreecommitdiff
path: root/src/commands/queue.ts
diff options
context:
space:
mode:
authorMax Isom <[email protected]>2020-03-18 12:40:31 -0500
committerMax Isom <[email protected]>2020-03-18 12:40:31 -0500
commit11246812a6e5da88750bf4b6ded159dd4020a3d3 (patch)
treea12d6bdd142c8e67b035bab4720cea64d444cd5c /src/commands/queue.ts
parent7844e80991d784eed107dd9a661dd5257ae49675 (diff)
downloadmuse-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.ts6
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)) + '`');
}
}