fixing if feeding same points in lines