Fixes #2522 : (maintenance) Predicate fails with NPE if field value is null

Fixes #2522 : Predicate fails with NPE if field value is null