Fix showing user black is avaiable when its not

This commit is contained in:
Artlef 2020-03-15 23:08:53 +01:00
parent b7ca43be33
commit 5796d742f6

View File

@ -228,7 +228,7 @@ fn prompt_user_for_role(client: &Client, stream: &mut UnixStream) -> Option<User
prompt.push_str("You can only spectate this game. Press enter to start spectating.");
} else if available_roles.contains(&UserRole::White) {
prompt = String::from("Do you want to play as White (W)");
if available_roles.contains(&UserRole::White) {
if available_roles.contains(&UserRole::Black) {
prompt.push_str(", Black (B)");
}
prompt.push_str(" or Spectate (S)?");