Skip to content

Commit

Permalink
the J
Browse files Browse the repository at this point in the history
  • Loading branch information
RacoonDog committed Aug 12, 2023
1 parent 70ba6d6 commit 2c22f92
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -251,12 +251,9 @@ private void onMessageReceive(ReceiveMessageEvent event) {
}

if (timestamps.get()) {
Matcher matcher = timestampRegex.matcher(message.getString());
if (matcher.matches()) message.getSiblings().subList(0, 8).clear();

Text timestamp = Text.literal("<" + dateFormat.format(new Date()) + "> ").formatted(Formatting.GRAY);

message = Text.literal("").append(timestamp).append(message);
message = Text.empty().append(timestamp).append(message);
}

event.setMessage(message);
Expand Down

0 comments on commit 2c22f92

Please sign in to comment.