Updated while loop to while boardHasOpenSpaces