Skip to content

Commit

Permalink
Merge pull request #625 from darbyjack/master
Browse files Browse the repository at this point in the history
Fixed parsing of the MOTD as Component
  • Loading branch information
Steven Smith committed Apr 6, 2021
2 parents afca99c + 3aa2159 commit 6af0257
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Expand Up @@ -74,7 +74,7 @@
<dependency>
<groupId>net.kyori</groupId>
<artifactId>adventure-text-serializer-gson</artifactId>
<version>4.2.0</version>
<version>4.7.0</version>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
Expand Down
Expand Up @@ -53,7 +53,7 @@ public void read(NetInput in) throws IOException {

PlayerInfo players = new PlayerInfo(plrs.get("max").getAsInt(), plrs.get("online").getAsInt(), profiles);
JsonElement desc = obj.get("description");
Component description = DefaultComponentSerializer.get().deserialize(desc.toString());
Component description = DefaultComponentSerializer.get().serializer().fromJson(desc, Component.class);
byte[] icon = null;
if(obj.has("favicon")) {
icon = this.stringToIcon(obj.get("favicon").getAsString());
Expand Down

0 comments on commit 6af0257

Please sign in to comment.