fixes collection filtering by keys
adds type check to Path.equals()