fix validation of bool types

This one is pretty self-explanatory; the logic for validating bool types was reversed. It looks like it was probably just a typo.

I found it while writing tests for the #9 implementation. It's fixed there, too, but I thought it was important and small enough that it made sense to submit it separately.