[<% @taxons.each_with_index do |t,i| %>
  { "attr" :
    { "id" : "<%= t.id %>" },
    "data" : "<%= escape_javascript(raw(t.name)) %>"
    <% unless t.children.empty? %>
      ,"state" : "closed"
    <% end %>
  }<%= "," if i < (@taxons.size - 1) %>
<% end %>]

[<% @taxons.each_with_index do |t,i| %>
  { "attr" :
    { "id" : "<%= t.id %>" },
    "data" : "<%= raw(t.name.gsub('"','\"')) %>"
    <% unless t.children.empty? %>
      ,"state" : "closed"
    <% end %>
  }<%= "," if i < (@taxons.size - 1) %>
<% end %>]

Fix issue where single quotes would break taxonomies/get_children response
Fix issue where single quotes would break taxonomies/get_children response

Fixes #2413
