Don't try to deserialize a null string in legacy method
Dieser Commit ist enthalten in:
Ursprung
9bcd08cb3c
Commit
aa282a1a04
@ -1612,7 +1612,7 @@ index 3a782294c15e2c2592976858e28ec33f049cb65e..772c6b2fa50deac27e5ed112e6d9f9dd
|
|||||||
public String getCustomName() {
|
public String getCustomName() {
|
||||||
TileEntityEnchantTable enchant = this.getSnapshot();
|
TileEntityEnchantTable enchant = this.getSnapshot();
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java b/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java b/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java
|
||||||
index 81f6bf5533288ed90e2f1f4d421d54195d9650c7..4daa39abc7ec1cae91d917a747efb192c2ca05eb 100644
|
index 81f6bf5533288ed90e2f1f4d421d54195d9650c7..d742f72215f6a9a2b562182fd57fd9acc59c9818 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java
|
--- a/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java
|
||||||
@@ -13,8 +13,10 @@ import org.bukkit.craftbukkit.util.CraftChatMessage;
|
@@ -13,8 +13,10 @@ import org.bukkit.craftbukkit.util.CraftChatMessage;
|
||||||
@ -1688,7 +1688,7 @@ index 81f6bf5533288ed90e2f1f4d421d54195d9650c7..4daa39abc7ec1cae91d917a747efb192
|
|||||||
public void setLine(int index, String line) throws IndexOutOfBoundsException {
|
public void setLine(int index, String line) throws IndexOutOfBoundsException {
|
||||||
- getLines()[index] = line;
|
- getLines()[index] = line;
|
||||||
+ this.loadLines();
|
+ this.loadLines();
|
||||||
+ this.lines.set(index, io.papermc.paper.adventure.PaperAdventure.LEGACY_SECTION_UXRC.deserialize(line)); // Paper
|
+ this.lines.set(index, line != null ? io.papermc.paper.adventure.PaperAdventure.LEGACY_SECTION_UXRC.deserialize(line) : net.kyori.adventure.text.Component.empty()); // Paper
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren