diff options
| author | Moulberry <james.jenour@student.scotch.wa.edu.au> | 2020-07-22 03:54:59 +1000 |
|---|---|---|
| committer | Moulberry <james.jenour@student.scotch.wa.edu.au> | 2020-07-22 03:54:59 +1000 |
| commit | d04771c7ef5cdab9554aa6aef506a39c8e2bd3d4 (patch) | |
| tree | 919df0469bbd4bf6234b4ea07e0b59ee5e011f9a /src/main/java/io/github/moulberry/notenoughupdates/auction | |
| parent | 8499a98beeb556c16987fc375dbd7d05d6c27ab4 (diff) | |
| download | notenoughupdates-d04771c7ef5cdab9554aa6aef506a39c8e2bd3d4.tar.gz notenoughupdates-d04771c7ef5cdab9554aa6aef506a39c8e2bd3d4.tar.bz2 notenoughupdates-d04771c7ef5cdab9554aa6aef506a39c8e2bd3d4.zip | |
less scuffed profile viewer :)
Diffstat (limited to 'src/main/java/io/github/moulberry/notenoughupdates/auction')
| -rw-r--r-- | src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java | 8 | ||||
| -rw-r--r-- | src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java | 2 |
2 files changed, 7 insertions, 3 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java b/src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java index 65f6545e..53cc4639 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java @@ -168,7 +168,9 @@ public class APIManager { args.put("uuid", ""+uuid); manager.hypixelApi.getHypixelApiAsync(manager.config.apiKey.value, "skyblock/profiles", args, jsonObject -> { - if(jsonObject.has("success") && jsonObject.get("success").getAsBoolean()) { + if(jsonObject == null) return; + + if(jsonObject.has("success") && jsonObject.get("success").getAsBoolean()) { incPlayerInfoVersion(); playerInformation = jsonObject.get("profiles").getAsJsonArray(); if(playerInformation == null) return; @@ -366,7 +368,9 @@ public class APIManager { args.put("page", ""+page); manager.hypixelApi.getHypixelApiAsync(manager.config.apiKey.value, "skyblock/auctions", args, jsonObject -> { - if (jsonObject.get("success").getAsBoolean()) { + if(jsonObject == null) return; + + if (jsonObject.get("success").getAsBoolean()) { totalPages = jsonObject.get("totalPages").getAsInt(); activeAuctions = jsonObject.get("totalAuctions").getAsInt(); diff --git a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java index 17ce216e..77fa8425 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java @@ -103,7 +103,7 @@ public class CustomAH extends Gui { private Category CATEGORY_TRAVEL_SCROLLS = new Category("travelscroll", "Travel Scrolls", "map"); private Category CATEGORY_REFORGE_STONES = new Category("reforgestone", "Reforge Stones", "anvil"); - private Category CATEGORY_RUNES = new Category("rune", "Runes", "end_portal_frame"); + private Category CATEGORY_RUNES = new Category("rune", "Runes", "magma_cream"); private Category CATEGORY_FURNITURE = new Category("furniture", "Furniture", "armor_stand"); private Category CATEGORY_COMBAT = new Category("weapon", "Combat", "golden_sword", CATEGORY_SWORD, |
