diff options
author | DoKM <mcazzyman@gmail.com> | 2021-08-01 15:05:27 +0200 |
---|---|---|
committer | DoKM <mcazzyman@gmail.com> | 2021-08-01 15:05:27 +0200 |
commit | 58aece3b67b0acca9466a83f53574489391de0ed (patch) | |
tree | 5f7bac6b2f5b8ef051fa3bcd3dbafaab6bd4d87e /src/main/java | |
parent | b6195af57bc6b6661bd1a2e429387d72aafc81f1 (diff) | |
download | NotEnoughUpdates-58aece3b67b0acca9466a83f53574489391de0ed.tar.gz NotEnoughUpdates-58aece3b67b0acca9466a83f53574489391de0ed.tar.bz2 NotEnoughUpdates-58aece3b67b0acca9466a83f53574489391de0ed.zip |
Removed unnessary duplicate code
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java b/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java index fdff55f3..56ed9502 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java @@ -147,7 +147,9 @@ public class GuiProfileViewer extends GuiScreen { } { //this is just to cache the guild info - JsonObject guildinfo = profile.getGuildInfo(null); + if(profile != null) { + JsonObject guildinfo = profile.getGuildInfo(null); + } } this.sizeX = 431; @@ -2224,14 +2226,6 @@ public class GuiProfileViewer extends GuiScreen { } { - String first_join = this.getTimeSinceString(profileInfo, "first_join"); - if(first_join != null) { - Utils.renderAlignedString(EnumChatFormatting.AQUA + "Joined", EnumChatFormatting.WHITE.toString() + first_join, - guiLeft + xStart, guiTop + yStartTop + yOffset * 3, 76); - } - - } - { JsonObject guildInfo = profile.getGuildInfo(null); if(guildInfo != null && guildInfo.has("name")){ Utils.renderAlignedString(EnumChatFormatting.AQUA + "Guild", EnumChatFormatting.WHITE.toString() + guildInfo.get("name").getAsString(), |