Fixed the checking for total exterior angles.