validate's interface was inconsistent. Sometimes, it would throw an error; sometimes, it would return false. This makes it consistent: always return a boolean.
I discovered this when I noticed that a test wasn't passing the right arguments to validate. When I fixed it, I got test failures.
(You could argue that this should work the other way: it should throw instead of returning a boolean. But that's a bigger breaking change.)
validate
's interface was inconsistent. Sometimes, it wouldthrow
an error; sometimes, it would returnfalse
. This makes it consistent: always return a boolean.I discovered this when I noticed that a test wasn't passing the right arguments to
validate
. When I fixed it, I got test failures.(You could argue that this should work the other way: it should throw instead of returning a boolean. But that's a bigger breaking change.)