fixes bug causing no exit mazes