Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

with_scope, operators and ruby 2.6 #44

Open
sbidoul opened this issue Aug 18, 2019 · 2 comments
Open

with_scope, operators and ruby 2.6 #44

sbidoul opened this issue Aug 18, 2019 · 2 comments

Comments

@sbidoul
Copy link
Member

sbidoul commented Aug 18, 2019

Hi,

It seems that with_scope keys containing an operator do not work with ruby 2.6.

As an example, the following syntax change makes them work again:

-      {% with_scope price.gt: {default: {discount: 0}}, "functions.in" => {id: product_functions } %}
+      {% with_scope "price.gt" => {default: {discount: 0}}, "functions.in" => {id: product_functions } %}

The symptom is that in places such as

keys has value "t" instead of the value the developer intended (such as function.in).

I'm not sure if this issue arises in locomotive-shopinvader or upstream in locomotive.

@sbidoul
Copy link
Member Author

sbidoul commented Aug 18, 2019

cc/ @lmignon

@sbidoul
Copy link
Member Author

sbidoul commented Aug 30, 2019

@sebastienbeau @rvalyi do you have any opinion on this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant