Fixed a weird is_scalar conflict

In some cases if $checked = false but is boolean and the value of the
field is 0 the is_scalar would evaluate to true which obviously shouldn't happen