check if obj is boolean.