aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornea <romangraef@gmail.com>2022-09-29 01:15:45 +0200
committernea <romangraef@gmail.com>2022-09-29 01:16:28 +0200
commit99a4e5748471800dde82c02d5421d1db681c9838 (patch)
tree7e30d0a79268b8c85a43f15a79b4c959d7833b66
parentbd2dcfbd8a51b038f399eda167677365db198a93 (diff)
downloadNotEnoughUpdates-99a4e5748471800dde82c02d5421d1db681c9838.tar.gz
NotEnoughUpdates-99a4e5748471800dde82c02d5421d1db681c9838.tar.bz2
NotEnoughUpdates-99a4e5748471800dde82c02d5421d1db681c9838.zip
Use api selected variable to find best profile
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/profileviewer/ProfileViewer.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/ProfileViewer.java b/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/ProfileViewer.java
index ec68071e..983cbf4e 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/ProfileViewer.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/ProfileViewer.java
@@ -887,6 +887,10 @@ public class ProfileViewer {
}
String cuteName = profile.get("cute_name").getAsString();
+ if (profile.has("selected") && profile.get("selected").getAsBoolean()) {
+ lastCuteName = cuteName;
+ break;
+ }
if (lastCuteName == null) lastCuteName = cuteName;
profileNames.add(cuteName);
if (member.has("last_save")) {