Skip to content

Commit

Permalink
Limit gist messages to 256 chars
Browse files Browse the repository at this point in the history
  • Loading branch information
Matyrobbrt committed May 11, 2024
1 parent d3e697f commit a0105c2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public void registerListeners(JDABuilder builder) {

// Only set the description to the contents if there's no codeblocks inside the message
if (matchFindingStart == 0) {
gist.description(it.getContentRaw());
gist.description(Utils.truncate(it.getContentRaw(), 256));
}

final var url = gist.create().getHtmlUrl().toString();
Expand Down

0 comments on commit a0105c2

Please sign in to comment.