Fix methods Domain._sort_polygon_2d(), Domain._sort_polygon_3d()