   node = data.rslt.obj
   name = data.rslt.new_name
 
-  url = Spree.url(base_url).clone()
+  url = new URL(base_url)
   url.pathname = url.pathname + '/' + node.attr("id")
 
   $.ajax

  node = data.rslt.o
  new_parent = data.rslt.np

  url = Spree.url(base_url).clone()
  url.pathname = url.pathname + '/' + node.attr("id")
  $.ajax
    type: "POST",

handle_delete = (e, data) ->
  last_rollback = data.rlbk
  node = data.rslt.obj
  delete_url = new URL(base_url)
  delete_url.pathname = delete_url.pathname + '/' + node.attr("id")
  if confirm(Spree.translations.are_you_sure_delete)
    $.ajax
      type: "POST",
