fix in add_point, changed to add_end_point