Fixed up some possible NPE's when dealing with filter field values that are null.