[Polyline] Bug fixes

Previously creating duplicate lines