Deduplicate fields.

Do this in getFormFields. Try not to do it repeatedly.
Tidying: don't pass keyword params with default values.