should be `form_end(form)` and the form_rest would not be needed anymore.