Skip to content

Commit

Permalink
Avoid Element.closest() for IE 9 compatibility
Browse files Browse the repository at this point in the history
Fixes #37234.
  • Loading branch information
georgeclaghorn committed Sep 29, 2019
1 parent dedd138 commit b425af0
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -11,7 +11,7 @@ Rails.serializeElement = (element, additionalParam) ->

inputs.forEach (input) ->
return if !input.name || input.disabled
return if input.closest('fieldset[disabled]')
return if matches(input, 'fieldset[disabled] *')
if matches(input, 'select')
toArray(input.options).forEach (option) ->
params.push(name: input.name, value: option.value) if option.selected
Expand Down

0 comments on commit b425af0

Please sign in to comment.