Ensure boolean attribute values get validated correctly

Fixes #1399