rails/jquery-ujs

does rails enforce data-method "GET" be uppercase?

nathanallen opened this issue · 1 comments

At a glance it seems possible that the data-method value could be a lowercase "get", which would fail this check

if (metaClick && (!method || method === 'GET') && !data) { return true; }

Confirm, it could. Methods are uppercase, but lowercase usage is common and exhibited elsewhere. data-method is typically omitted entirely for GET requests, which may be why nobody has noticed. PR welcome to add support for lowercase get in this case 😊