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
Mounted engines don't get route segment values #529
Comments
I've found the problem and got a solution. If you merge in
@josh, do you want me to open pull request for rack-mount to fix it? |
Its not a simple as merging. We'd need to maintain a stack of params.
Its possible to have a request match A -> B -> 1 then returns |
Right. Do you want some help to implement it? And if so, where would be the best place to implement it? In |
Please do You should just have to modify Open a pull request and I'll walk you through the edge cases. |
Pull request created, closing this issue. |
@samuelkadolph, could you also please add a test to Rails? One of the appropriated places to put this test would be in the file below. You just need to nest to route sets. https://github.com/rails/rails/blob/master/actionpack/test/dispatch/mount_test.rb |
@josevalim I have added test here for the main problem in engine_test if we need then can add here also |
Ah, no need then. Thanks @arunagw! |
So I've been playing with the 3.1 beta and I really want to package our code as an engine in a gem and also release a multitenant version that lets you mount the engine to
/:username
. This works fine but it doesn't pass the value of the segment into to controller that the route maps to inside of the engine.The text was updated successfully, but these errors were encountered: