1
0
Fork 0
mirror of https://github.com/PaperMC/Paper.git synced 2025-02-03 21:37:28 +01:00

Dont strip explicit leading color codes in chat components ()

This commit is contained in:
BillyGalbreath 2018-10-02 09:21:12 -05:00
parent 74661b79f0
commit cd4848b2e6

View file

@ -0,0 +1,20 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: BillyGalbreath <Blake.Galbreath@GMail.com>
Date: Sun, 30 Sep 2018 08:40:14 -0500
Subject: [PATCH] Dont strip explicit leading color codes in chat components
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftChatMessage.java b/src/main/java/org/bukkit/craftbukkit/util/CraftChatMessage.java
index 5e20a9a61..df627d955 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftChatMessage.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftChatMessage.java
@@ -0,0 +0,0 @@ public final class CraftChatMessage {
}
out.append(c.getText());
}
- return out.toString().replaceFirst("^(" + defaultColor + ")*", "");
+ return out.toString().replaceFirst("^(" + defaultColor + ")", ""); // Paper - GH-1484
}
public static IChatBaseComponent fixComponent(IChatBaseComponent component) {
--