   if $wrapper.find('.effective-datatables-inline-row').length == 0
     $wrapper.removeClass('effective-datatables-inline-expanded')
 
-redirectDatatables = ($source) ->
-  return false unless EffectiveForm.remote_form_refresh_datatables.length > 0
-
-  if EffectiveForm.remote_form_refresh_datatables.includes('refresh')
-    if Turbolinks?
-      Turbolinks.visit(window.location.href, { action: 'replace'})
-    else
-      window.location.reload()
-
-    return true
-
-  false
-
-refreshDatatables = ($source) ->
-  return unless EffectiveForm.remote_form_refresh_datatables.length > 0
-
-  $('table.dataTable.initialized').each ->
-    $table = $(this)
-
-    if EffectiveForm.remote_form_refresh_datatables.find((id) -> $table.attr('id').startsWith(id) || id == 'all')
-      $table.DataTable().draw() if $table != $source
-
 # Cancel button clicked. Blow away new tr, or restore edit tr
 # No data will have changed at this point
 $(document).on 'click', ".dataTables_wrapper a[data-role='inline-form-cancel']", (event) ->

  EffectiveForm.remote_form_payload = ''
  EffectiveForm.remote_form_commit = ''
  EffectiveForm.remote_form_flash = ''
  EffectiveForm.remote_form_refresh_datatables = ''
  true

# Submitting an inline datatables form

  else
    $table.DataTable().flash('Successfully ' + $action.attr('title'), 'success')

  $table.DataTable().draw()

afterError = ($action) ->
  $table = $action.closest('table')
