Skip to content

Commit

Permalink
added another workaround to interaction expiry
Browse files Browse the repository at this point in the history
  • Loading branch information
Mast3rwaf1z committed Dec 14, 2023
1 parent 547ac7b commit 8152410
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/src/main/java/wordcount/actions/Makepdf.java
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public CommandResponse execute() {
percentage+=0.1;
percentages.put(channel, (int)(percentage*100));
if(!test){
((SlashCommandInteractionEvent)event).getHook().editOriginal("```\n"+percentages.keySet().stream().sorted((e1, e2) -> Integer.compare(percentages.get(e2), percentages.get(e1))).map(key -> String.format("%s: %s%%", key.getName(), percentages.get(key))).collect(Collectors.joining("\n"))+"\n```").queue();
this.message.editMessage("Progress\n```\n"+percentages.keySet().stream().sorted((e1, e2) -> Integer.compare(percentages.get(e2), percentages.get(e1))).map(key -> String.format("%s: %s%%", key.getName(), percentages.get(key))).collect(Collectors.joining("\n"))+"\n```").queue();
}
}
System.out.println("["+channel.getName()+"] Getting message content");
Expand Down

0 comments on commit 8152410

Please sign in to comment.