Here you may also have more than two points, e.g. where a ring is closed. But since the for loop below works regardless of the number of hits, you can just remove the `if`.