refactored into form object