diff --git a/src/path/Curve.js b/src/path/Curve.js index 0aad6847..7030c9a5 100644 --- a/src/path/Curve.js +++ b/src/path/Curve.js @@ -231,7 +231,7 @@ var Curve = this.Curve = Base.extend(/** @lends Curve# */{ getLength: function(/* from, to */) { // Hide parameters from Bootstrap so it injects bean too var from = arguments[0], - to = arguments[1]; + to = arguments[1], fullLength = arguments.length == 0 || from == 0 && to == 1; if (fullLength && this._length != null) return this._length; @@ -693,7 +693,7 @@ var Curve = this.Curve = Base.extend(/** @lends Curve# */{ for (var i = 0; i <= degree; i++) w[i] = new Point(i / degree, 0); - for (k = 0; k <= degree; k++) { + for (var k = 0; k <= degree; k++) { var lb = Math.max(0, k - n + 1), ub = Math.min(k, n); for (var i = lb; i <= ub; i++) { diff --git a/src/path/Path.js b/src/path/Path.js index c2a535ff..3dc6ce66 100644 --- a/src/path/Path.js +++ b/src/path/Path.js @@ -1691,8 +1691,8 @@ var Path = this.Path = PathItem.extend(/** @lends Path# */{ }, cubicCurveTo: function(handle1, handle2, to) { - var _handle1 = Point.read(arguments); - _handle2 = Point.read(arguments); + var _handle1 = Point.read(arguments), + _handle2 = Point.read(arguments), _to = Point.read(arguments); // First modify the current segment: var current = getCurrentSegment(this); diff --git a/test/tests/SvgExport.js b/test/tests/SvgExport.js index 0fc83579..d3cc9f11 100644 --- a/test/tests/SvgExport.js +++ b/test/tests/SvgExport.js @@ -357,7 +357,7 @@ test('compare ellipse values', function() { var shape = document.createElementNS(svgns, 'ellipse'); var cx = 100, cy = 80, - rx = 50; + rx = 50, ry = 30; shape.setAttribute('cx', cx); shape.setAttribute('cy', cy);