Refactor field searching