Skip to content

Commit 850b0a8

Browse files
Bhagyesh Vikaninturley
authored andcommitted
Handle empty section.bendPoints (#84)
1 parent 534d4db commit 850b0a8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

built/drawModule.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,13 +153,13 @@ function removeDummyEdges(g) {
153153
var section = edge.sections[0];
154154
if (dummyIsSource) {
155155
// get first bend or endPoint
156-
if (section.bendPoints) {
156+
if (section.bendPoints && section.bendPoints.length > 0) {
157157
return [section.bendPoints[0]];
158158
}
159159
return section.endPoint;
160160
}
161161
else {
162-
if (section.bendPoints) {
162+
if (section.bendPoints && section.bendPoints.length > 0) {
163163
return [_.last(section.bendPoints)];
164164
}
165165
return section.startPoint;

0 commit comments

Comments
 (0)