diff --git a/build.gradle.kts b/build.gradle.kts index 04c454f..ce48c43 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -6,7 +6,7 @@ plugins { } group = "net.azisaba.azipluginmessaging" -version = "2.1.2" +version = "2.1.3" repositories { mavenCentral() diff --git a/spigot/src/main/java/net/azisaba/azipluginmessaging/spigot/entity/PlayerImpl.java b/spigot/src/main/java/net/azisaba/azipluginmessaging/spigot/entity/PlayerImpl.java index bb57c36..74a333a 100644 --- a/spigot/src/main/java/net/azisaba/azipluginmessaging/spigot/entity/PlayerImpl.java +++ b/spigot/src/main/java/net/azisaba/azipluginmessaging/spigot/entity/PlayerImpl.java @@ -116,8 +116,8 @@ public boolean isChallengeEquals(@NotNull String challenge) { public String toString() { return "PlayerImpl{" + "handle=" + handle + - ", publicKey=" + EncryptionUtil.encodePublicKey(keyPair.getPublic()) + - ", remotePublicKey=" + EncryptionUtil.encodePublicKey(remotePublicKey) + + ", publicKey=" + (keyPair == null ? null : EncryptionUtil.encodePublicKey(keyPair.getPublic())) + + ", remotePublicKey=" + (remotePublicKey == null ? null : EncryptionUtil.encodePublicKey(remotePublicKey)) + ", encrypted=" + encrypted + '}'; } diff --git a/velocity/src/main/java/net/azisaba/azipluginmessaging/velocity/server/ServerConnectionImpl.java b/velocity/src/main/java/net/azisaba/azipluginmessaging/velocity/server/ServerConnectionImpl.java index b7a3cb1..72eefe0 100644 --- a/velocity/src/main/java/net/azisaba/azipluginmessaging/velocity/server/ServerConnectionImpl.java +++ b/velocity/src/main/java/net/azisaba/azipluginmessaging/velocity/server/ServerConnectionImpl.java @@ -112,8 +112,8 @@ public String toString() { return "ServerConnectionImpl{" + "handle=" + handle + ", encrypted=" + encrypted + - ", publicKey=" + EncryptionUtil.encodePublicKey(keyPair.getPublic()) + - ", remotePublicKey=" + EncryptionUtil.encodePublicKey(publicKey) + + ", publicKey=" + (keyPair == null ? null : EncryptionUtil.encodePublicKey(keyPair.getPublic())) + + ", remotePublicKey=" + (publicKey == null ? null : EncryptionUtil.encodePublicKey(publicKey)) + '}'; } }