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

Rails Security update for the Polymorphic routes #2188

Closed
wants to merge 2 commits into from

Conversation

codegeek319
Copy link

What is this pull request for?

Rails has updated it's polymorphic routes for security purposes and it was casing the issue when creating nodes in the CMS which is why we have added this code as The new Security Update don't take String as an parameter so we have to explicitly convert it into an Symbol using ruby to_sym other than that the parameters are acceptable. In the resources_helper.rb file on line no 33 when we are using resource_handler.namespace_for_scope it gives us an array like ["admin"] which is a string and it's hard coded into the Alchemy variable @admin_path variable as a string so for this purpose we have create a function which will take this parameter and then map if there are any string available then convert them into Symbols

Checklist

  • [*] I have followed Pull Request guidelines
  • [*] I have added a detailed description into each commit message
  • [] I have added tests to cover this change

@tvdeyen
Copy link
Member

tvdeyen commented Sep 12, 2021

Thanks. Could you please add specs and rebase with latest main, to get the Rails 6.1 support we just merged.

@tvdeyen
Copy link
Member

tvdeyen commented Nov 23, 2021

Just figured out we already fixed this in #2087

@tvdeyen tvdeyen closed this Nov 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants