diff --git a/lib/assets/javascripts/nested_form_fields.js.coffee b/lib/assets/javascripts/nested_form_fields.js.coffee index 3f06cce..b5afc63 100644 --- a/lib/assets/javascripts/nested_form_fields.js.coffee +++ b/lib/assets/javascripts/nested_form_fields.js.coffee @@ -22,12 +22,7 @@ nested_form_fields.bind_nested_forms_links = () -> # look for replacements in user defined code and substitute with the index template_html = template_html.replace(new RegExp("__nested_field_for_replace_with_index__","g"), added_index) - # replace child template div tags with script tags to avoid form submission of templates $parsed_template = $(template_html) - $child_templates = $parsed_template.closestChild('.form_template') - $child_templates.each () -> - $child = $(this) - $child.replaceWith($("