You don't need this `and`.  `hasFields` returns `false` if a field is `null`.