reworked form cleanup after submit