Broke out the logic to find the winning node.