Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
pixelzoom committed Sep 14, 2023
1 parent 1791faa commit 3e56473
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions js/faradays-law/view/MagnetRegionManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -143,10 +143,9 @@ class MagnetRegionManager {
const listOfRestrictedBounds = this.model.bottomCoilRestrictedBounds.concat( this.model.topCoilRestrictedBounds );
const i = listOfRestrictedBounds.indexOf( intersectedBounds );

// TODO: The code below looks wrong. The return type doesn't match the header docs, and the whole thing is too https://github.com/phetsims/tasks/issues/1129
// tightly coupled to the way bounds are managed in the model. See
// https://github.com/phetsims/faradays-law/issues/164. Also, it seems like it should return null instead of -1 if
// no intersection is found.
//TODO https://github.com/phetsims/faradays-law/issues/164 The code below looks wrong. The return type doesn't
// match the header docs, and the whole thing is too tightly coupled to the way bounds are managed in the model.
// Also, it seems like it should return null instead of -1 if no intersection is found.

if ( i >= 0 ) {
return coilSides[ i ];
Expand Down

0 comments on commit 3e56473

Please sign in to comment.