Skip to content

Commit

Permalink
Don't allow continue from the connecting vertex of a closed way
Browse files Browse the repository at this point in the history
Now that addNode tries to preserve circularity, this
could cause the continued segment to loop back.

And anyway it's confusing why one vertex allows it and none others do.
  • Loading branch information
bhousel committed Jan 12, 2017
1 parent 45b7a40 commit cb35873
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions modules/operations/continue.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ export function operationContinue(selectedIDs, context) {
function candidateWays() {
return graph.parentWays(vertex).filter(function(parent) {
return parent.geometry(graph) === 'line' &&
!parent.isClosed() &&
parent.affix(vertex.id) &&
(geometries.line.length === 0 || geometries.line[0] === parent);
});
Expand Down

0 comments on commit cb35873

Please sign in to comment.