Fix the comparison for null/boolean values