Skip to content

Commit c193a04

Browse files
committed
empty path fix
1 parent 6f2bd0f commit c193a04

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

svgpath/path.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -489,7 +489,10 @@ def measure(self, start, end, error=ERROR, min_depth=MIN_DEPTH):
489489

490490
def _is_closable(self):
491491
"""Returns true if the end is on the start of a segment"""
492-
end = self[-1].end
492+
try:
493+
end = self[-1].end
494+
except:
495+
return False
493496
for segment in self:
494497
if segment.start == end:
495498
return True

0 commit comments

Comments
 (0)