fix: use geom_type instead of type for Shapely objects

This commit is contained in:
Daniel Wong
2025-05-09 14:29:27 -06:00
parent ba47f1fae5
commit 77eb6e8254

View File

@@ -3399,7 +3399,7 @@ class ImageResponse(LoncapaResponse):
parsed_region = [parsed_region]
for region in parsed_region:
polygon = MultiPoint(region).convex_hull
if (polygon.type == 'Polygon' and
if (polygon.geom_type == 'Polygon' and
polygon.contains(Point(ans_x, ans_y))):
correct_map.set(aid, 'correct')
break