If I define a route inside a module, like this:
class DrivenSignupPlugin::AccountController < ApplicationController
...
end
Then all calls to url_for (including redirect_to) inside it will prefix the :controller parameter with driven_signup_plugin/.
This is not the desired behaviour as this controller uses many routes outside it. For example, render_access_denied is a method from ApplicationController.
To workaround this, add this method to the controller:
For Rails 4.2+, something more complicated is needed: