File tree Expand file tree Collapse file tree 1 file changed +3
-9
lines changed
application/src/main/java/org/togetherjava/tjbot/commands/tags Expand file tree Collapse file tree 1 file changed +3
-9
lines changed Original file line number Diff line number Diff line change 1515import org .slf4j .LoggerFactory ;
1616import org .togetherjava .tjbot .commands .SlashCommandAdapter ;
1717import org .togetherjava .tjbot .commands .SlashCommandVisibility ;
18- import org .togetherjava .tjbot .commands .utils .MessageUtils ;
1918import org .togetherjava .tjbot .config .Config ;
2019
20+ import java .nio .charset .StandardCharsets ;
2121import java .time .Instant ;
2222import java .util .Objects ;
2323import java .util .OptionalLong ;
@@ -154,14 +154,8 @@ private void rawTag(@NotNull SlashCommandEvent event) {
154154 return ;
155155 }
156156
157- event
158- .replyEmbeds (new EmbedBuilder ()
159- .setDescription (MessageUtils .escapeMarkdown (tagSystem .getTag (id ).orElseThrow ()))
160- .setFooter (event .getUser ().getName ())
161- .setTimestamp (Instant .now ())
162- .setColor (TagSystem .AMBIENT_COLOR )
163- .build ())
164- .queue ();
157+ String content = tagSystem .getTag (id ).orElseThrow ();
158+ event .reply ("" ).addFile (content .getBytes (StandardCharsets .UTF_8 ), "content.md" ).queue ();
165159 }
166160
167161 private void createTag (@ NotNull CommandInteraction event ) {
You can’t perform that action at this time.
0 commit comments