Fix DOM after clearing <form> on unsuccessful attachment

This ensures that the FILES request goes through properly after attaching a
forbidden file and then correcting the error.