fix logic to remove false negatives