phetsims / molarity

"Molarity" is an educational simulation in HTML5, by PhET Interactive Simulations.
http://phet.colorado.edu/en/simulation/molarity
GNU General Public License v3.0
2 stars 6 forks source link

`ConcentrationDescriber.concentrationIncreased` Review #175

Closed zepumph closed 4 years ago

zepumph commented 5 years ago

From #171

lighterDarker: this.concentrationIncreased ? darkerString : lighterString

unless you would want "lighterString" if null or boolean. There should be an assertion making sure that it is a boolean, or documentation as to how null and false are being treated the same here.

I think the more explicit you can be here, the better it will be. If ever there is a method here that shouldn't be called if concentrationIncreased is null, I think that should be asserted.

twant commented 4 years ago

I think this is solved by the changes in #180. @zepumph assigning over to you to review and close if you agree.