diff options
author | Guillermo Iguaran <guilleiguaran@gmail.com> | 2017-10-29 23:28:16 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-29 23:28:16 -0500 |
commit | ee44c1b6f1ca3a8ee685807a940cf02101ed5141 (patch) | |
tree | d423f037031d943d6587cac085e42ebea5803482 /actionview/app | |
parent | 8479b79a0a4dad21a36e69a4502ff7414c250949 (diff) | |
parent | 8b22725c782a65b2222f7a9ffed6d241c599f2e6 (diff) | |
download | rails-ee44c1b6f1ca3a8ee685807a940cf02101ed5141.tar.gz rails-ee44c1b6f1ca3a8ee685807a940cf02101ed5141.tar.bz2 rails-ee44c1b6f1ca3a8ee685807a940cf02101ed5141.zip |
Merge pull request #31002 from ta1kt0me/call_ajax_without_beforeSend
Call Rails.ajax without beforeSend
Diffstat (limited to 'actionview/app')
-rw-r--r-- | actionview/app/assets/javascripts/rails-ujs/utils/ajax.coffee | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionview/app/assets/javascripts/rails-ujs/utils/ajax.coffee b/actionview/app/assets/javascripts/rails-ujs/utils/ajax.coffee index 4d7848e162..cc0e037428 100644 --- a/actionview/app/assets/javascripts/rails-ujs/utils/ajax.coffee +++ b/actionview/app/assets/javascripts/rails-ujs/utils/ajax.coffee @@ -21,7 +21,7 @@ Rails.ajax = (options) -> options.error?(response, xhr.statusText, xhr) options.complete?(xhr, xhr.statusText) - unless options.beforeSend?(xhr, options) + if options.beforeSend? && !options.beforeSend(xhr, options) return false if xhr.readyState is XMLHttpRequest.OPENED |