Remove redundant code and tidy up build.
Tidy up text field naming.