Fixed bug where checking for the presence of neighbors of similar color was not working