Skip to content

Commit

Permalink
change let -> const if not reassigned, phetsims/tasks#973
Browse files Browse the repository at this point in the history
  • Loading branch information
zepumph committed Dec 12, 2018
1 parent f3e96e5 commit 8a51451
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions js/segments/Cubic.js
Original file line number Diff line number Diff line change
Expand Up @@ -1152,13 +1152,13 @@ define( function( require ) {
// Examine the single-coordinate distances between the "overlaps" at each extreme T value. If the distance is larger
// than our epsilon, then the "overlap" would not be valid.
for ( let i = 0; i < xExtremeTs.length; i++ ) {
let t = xExtremeTs[ i ];
const t = xExtremeTs[ i ];
if ( Math.abs( ( ( d3x * t + d2x ) * t + d1x ) * t + d0x ) > epsilon ) {
return noOverlap;
}
}
for ( let i = 0; i < yExtremeTs.length; i++ ) {
let t = yExtremeTs[ i ];
const t = yExtremeTs[ i ];
if ( Math.abs( ( ( d3y * t + d2y ) * t + d1y ) * t + d0y ) > epsilon ) {
return noOverlap;
}
Expand Down
4 changes: 2 additions & 2 deletions js/segments/Quadratic.js
Original file line number Diff line number Diff line change
Expand Up @@ -796,13 +796,13 @@ define( function( require ) {
// Examine the single-coordinate distances between the "overlaps" at each extreme T value. If the distance is larger
// than our epsilon, then the "overlap" would not be valid.
for ( let i = 0; i < xExtremeTs.length; i++ ) {
let t = xExtremeTs[ i ];
const t = xExtremeTs[ i ];
if ( Math.abs( ( d2x * t + d1x ) * t + d0x ) > epsilon ) {
return noOverlap;
}
}
for ( let i = 0; i < yExtremeTs.length; i++ ) {
let t = yExtremeTs[ i ];
const t = yExtremeTs[ i ];
if ( Math.abs( ( d2y * t + d1y ) * t + d0y ) > epsilon ) {
return noOverlap;
}
Expand Down

0 comments on commit 8a51451

Please sign in to comment.