Skip to content

Commit

Permalink
Fixed forgotten restaction queue for delete messages.
Browse files Browse the repository at this point in the history
  • Loading branch information
DV8FromTheWorld committed Jan 4, 2017
1 parent 1bb21f3 commit a5ed69d
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ else if (args[1].startsWith("-"))
success = addTodo(StringUtils.join(args, " ", 1, args.length), e);

if (success)
e.getMessage().deleteMessage();
e.getMessage().deleteMessage().queue();
}

private boolean addTodo(String todoMessage, MessageReceivedEvent e)
Expand Down Expand Up @@ -169,9 +169,9 @@ private boolean clearTodo()
}
}
if (oldMessageIds.size() > 1)
api.getTextChannelById(TODO_CHANNEL_ID).deleteMessagesByIds(oldMessageIds);
api.getTextChannelById(TODO_CHANNEL_ID).deleteMessagesByIds(oldMessageIds).queue();
else
api.getTextChannelById(TODO_CHANNEL_ID).deleteMessageById(oldMessageIds.get(0));
api.getTextChannelById(TODO_CHANNEL_ID).deleteMessageById(oldMessageIds.get(0)).queue();
todoList = new JSONArray();
for (JSONObject entry : savedEntries)
{
Expand Down

0 comments on commit a5ed69d

Please sign in to comment.