aboutsummaryrefslogtreecommitdiff
path: root/src/utils/loading-message.ts
diff options
context:
space:
mode:
authorMax Isom <[email protected]>2020-03-20 20:47:04 -0500
committerMax Isom <[email protected]>2020-03-20 20:47:04 -0500
commit9c91ce1a13cad701bc8876fd07ac4d513522a215 (patch)
tree582d5c7a17f2f476c563fd5aa635db02bb0c9394 /src/utils/loading-message.ts
parent646f030781df0f4fe03437d0ed2294a10fa6c177 (diff)
downloadmuse-9c91ce1a13cad701bc8876fd07ac4d513522a215.tar.xz
muse-9c91ce1a13cad701bc8876fd07ac4d513522a215.zip
Merge Player and Queue services
Diffstat (limited to 'src/utils/loading-message.ts')
-rw-r--r--src/utils/loading-message.ts8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/utils/loading-message.ts b/src/utils/loading-message.ts
index dd3e9b9..115aff2 100644
--- a/src/utils/loading-message.ts
+++ b/src/utils/loading-message.ts
@@ -60,10 +60,16 @@ export default class {
}
async stop(str = 'u betcha'): Promise<Message> {
+ const wasAlreadyStopped = this.isStopped;
+
this.isStopped = true;
if (str) {
- await Promise.all([this.msg.reactions.removeAll(), this.msg.edit(str)]);
+ if (wasAlreadyStopped) {
+ await this.msg.edit(str);
+ } else {
+ await Promise.all([this.msg.reactions.removeAll(), this.msg.edit(str)]);
+ }
} else {
await this.msg.reactions.removeAll();
}