selectable custom fields & refactor