fixing the form for edit