Skip to content

Commit

Permalink
Minor fixes for Closure compilation compatibility. (#200)
Browse files Browse the repository at this point in the history
  • Loading branch information
aomarks authored and samthor committed Dec 12, 2018
1 parent 3f9af6b commit ae52749
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/shadow-handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@
shadow.inset = true;
return result;
}
var result = scope.consumeLengthOrPercent(string);
result = scope.consumeLengthOrPercent(string);
if (result) {
shadow.lengths.push(result[0]);
return result;
}
var result = scope.consumeColor(string);
result = scope.consumeColor(string);
if (result) {
shadow.color = result[0];
return result;
Expand Down
4 changes: 2 additions & 2 deletions src/timing-utilities.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@
},
set iterationStart(value) {
if ((isNaN(value) || value < 0) && isInvalidTimingDeprecated()) {
throw new TypeError('iterationStart must be a non-negative number, received: ' + timing.iterationStart);
throw new TypeError('iterationStart must be a non-negative number, received: ' + value);
}
this._setMember('iterationStart', value);
},
Expand Down Expand Up @@ -192,9 +192,9 @@
}

var start = 0, end = 1;
function f(a, b, m) { return 3 * a * (1 - m) * (1 - m) * m + 3 * b * (1 - m) * m * m + m * m * m};
while (start < end) {
var mid = (start + end) / 2;
function f(a, b, m) { return 3 * a * (1 - m) * (1 - m) * m + 3 * b * (1 - m) * m * m + m * m * m};
var xEst = f(a, c, mid);
if (Math.abs(x - xEst) < 0.00001) {
return f(b, d, mid);
Expand Down

0 comments on commit ae52749

Please sign in to comment.