From 4a7add4cb111591930d10444024e8d0e93e3fdb9 Mon Sep 17 00:00:00 2001 From: riverwanderer <58135975+riverwanderer@users.noreply.github.com> Date: Sat, 9 Sep 2023 22:49:52 +0100 Subject: [PATCH] Integrate finish() and promptForSide(). --- .../src/main/java/VASSAL/build/module/PlayerRoster.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vassal-app/src/main/java/VASSAL/build/module/PlayerRoster.java b/vassal-app/src/main/java/VASSAL/build/module/PlayerRoster.java index fc776429ba..e14429560c 100644 --- a/vassal-app/src/main/java/VASSAL/build/module/PlayerRoster.java +++ b/vassal-app/src/main/java/VASSAL/build/module/PlayerRoster.java @@ -772,9 +772,12 @@ protected String promptForSide(String newSide) { } else { fromWizard = true; + if (newSide == null) { + newSide = ""; + } } - while (newSide != null && !newSide.isEmpty()) { // Loops until a valid side is found or op is canceled (repeats side check to minimuse race condition window) + while (newSide != null) { // Loops until a valid side is found or op is canceled (repeats side check to minimuse race condition window) for (final PlayerInfo p : players) { alreadyTaken.add(p.side);