From ac4a1565a100641d5fcc6fba817b99ffbdb7fe0a Mon Sep 17 00:00:00 2001 From: Ali Moghnieh Date: Sat, 18 Jun 2016 14:08:58 +0100 Subject: [PATCH] Implement empty OfflinePlayer methods instead of NSY exceptions. --- Essentials/src/com/earth2me/essentials/OfflinePlayer.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Essentials/src/com/earth2me/essentials/OfflinePlayer.java b/Essentials/src/com/earth2me/essentials/OfflinePlayer.java index ca28901d7..9d6744b2b 100644 --- a/Essentials/src/com/earth2me/essentials/OfflinePlayer.java +++ b/Essentials/src/com/earth2me/essentials/OfflinePlayer.java @@ -1459,11 +1459,13 @@ public class OfflinePlayer implements Player { @Override public void sendTitle(String title, String subtitle) { - throw new UnsupportedOperationException("Not supported yet."); + } @Override public AttributeInstance getAttribute(Attribute attribute) { - throw new UnsupportedOperationException("Not supported yet."); + // GetAttribute is nullable as per CraftAttributeMap. This might need to be + // improved to support cases where dummy null instances should be returned. + return null; } -} \ No newline at end of file +}