It’s a type check. It’s doing what it is suppose to. If you’re looking to ensure a value, than use a filter_var instead.