mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-05 20:32:00 -05:00
Fix index issue in #removeSegments().
This commit is contained in:
parent
121ec5a93f
commit
d098c6e8b2
1 changed files with 1 additions and 1 deletions
|
@ -116,7 +116,7 @@ var Path = this.Path = PathItem.extend({
|
|||
|
||||
// TODO: Port back to Sg
|
||||
removeSegments: function(from, to) {
|
||||
var i = Base.pick(to, this._segments.length),
|
||||
var i = Base.pick(to, this._segments.length - 1),
|
||||
from = from || 0;
|
||||
while (i >= from)
|
||||
this.removeSegment(i--);
|
||||
|
|
Loading…
Reference in a new issue