filter out the last point of a polygon to account for GeoJSON compatibility

Written in response to #1135. This pull filters out the last point of polygons that were created with the GeoJSON spec in mind.