From 39398acf82318d84407a89d2c9229a061a3936ef Mon Sep 17 00:00:00 2001 From: nathanallen Date: Thu, 15 Feb 2018 19:24:11 -0800 Subject: [PATCH] ensure data-method value is uppercase before comparison, fixes #507 --- src/rails.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rails.js b/src/rails.js index 7eee3906..8ed6d8b0 100644 --- a/src/rails.js +++ b/src/rails.js @@ -431,7 +431,7 @@ if (!metaClick && link.is(rails.linkDisableSelector)) rails.disableElement(link); if (rails.isRemote(link)) { - if (metaClick && (!method || method === 'GET') && !data) { return true; } + if (metaClick && (!method || method.toUpperCase() === 'GET') && !data) { return true; } var handleRemote = rails.handleRemote(link); // Response from rails.handleRemote() will either be false or a deferred object promise.