Merge pull request #892 from IAISI/master

Fix NPE, update dependencies
This commit is contained in:
Brokkonaut
2024-02-12 06:32:15 +01:00
committed by GitHub
2 changed files with 6 additions and 6 deletions

10
pom.xml
View File

@ -62,13 +62,13 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<version>4.13.2</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP</artifactId>
<version>5.0.1</version>
<version>5.1.0</version>
<scope>compile</scope>
</dependency>
</dependencies>
@ -125,7 +125,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.10.1</version>
<version>3.12.1</version>
<configuration>
<release>17</release>
</configuration>
@ -133,7 +133,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>3.3.0</version>
<version>3.5.0</version>
<executions>
<execution>
<id>regex-property</id>
@ -153,7 +153,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.3.0</version>
<version>3.5.1</version>
<configuration>
</configuration>
<executions>

View File

@ -73,7 +73,7 @@ public class BlockStateCodecSkull implements BlockStateCodec {
PlayerProfile profile = (PlayerProfile) conf.get("profile");
if (profile != null) {
TextComponent tc = new TextComponent("[" + (profile.getName() != null ? profile.getName() : (profile.getUniqueId() != null ? profile.getUniqueId().toString() : "~unknown~")) + "]");
if (profile.getName() != null) {
if (profile.getName() != null && profile.getUniqueId() != null) {
tc.setHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, new Text("UUID: " + profile.getUniqueId().toString())));
}
return tc;