Fix bugs in new file predicates