Closed Denz1994 closed 7 years ago
rate.equals() follows the same format
// @public
equals: function( object ) {
return ( object instanceof Rate ) &&
( object.numeratorProperty.value === this.numeratorProperty.value) &&
( object.denominatorProperty.value === this.denominatorProperty.value);
}
I've used Rate.toString
repeatedly to inspect Rate
instances in the console. And I feel that it will be useful for future maintenance, so it stays.
I've removed Rate.equals
. Was used in some early debugging, but unlikely to be useful in the future.
Btw... In general, toString
and equals
are common things to implement for types, whether they are used or not, and especially for debugging.
Back to @Denz1994 to verify.
Makes sense. There are no references to Rate.equals
. Closing.
@pixelzoom Should functions used for debugging and not explicitly called be removed from the published sim or will these functions help with maintenance?
For example : common/model/rate.js