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

Fixed issue with NoMethodError in ActionDispatch::Routing::Mapper with Rails 5 ( backward compatible ) #208

Merged
merged 1 commit into from
May 29, 2016

Conversation

bogdanRada
Copy link
Contributor

@bogdanRada bogdanRada commented May 24, 2016

I currently tried using this gem in a rails 5 application ( rails 5.0.0.rc1)
and i am currently using this routes:

namespace :api do
    wash_out :project_service,  module: 'Api'
  end

which results in this error when trying to run the rails server with command rails s

/.rvm/gems/ruby-2.3.0@washout_builder_demo/bundler/gems/wash_out-ffa1bf83bed1/lib/wash_out.rb:24:
in `block in wash_out': undefined method `[]=' for 
<ActionDispatch::Routing::Mapper::Scope:0x00000003ce99d0> (NoMethodError)

I am currently using the latest commit from master from this repository.

This fixes this issue and also preserves backward compatibility with older rails versions.

Please let me know what you think. Thank you very much.

@bogdanRada bogdanRada changed the title Fixing NoMethodError in ActionDispatch::Routing::Mapper in wash_out method when trying to use it in Rails 5 application ( backward compatible ) NoMethodError in ActionDispatch::Routing::Mapper with Rails 5 application ( backward compatible ) May 25, 2016
@bogdanRada bogdanRada changed the title NoMethodError in ActionDispatch::Routing::Mapper with Rails 5 application ( backward compatible ) NoMethodError in ActionDispatch::Routing::Mapper with Rails 5 ( backward compatible ) May 25, 2016
@bogdanRada bogdanRada changed the title NoMethodError in ActionDispatch::Routing::Mapper with Rails 5 ( backward compatible ) Fixed issue with NoMethodError in ActionDispatch::Routing::Mapper with Rails 5 ( backward compatible ) May 25, 2016
@bogdanRada
Copy link
Contributor Author

Sorry about the multiple name changes, the first one was way too long .

@inossidabile inossidabile merged commit 1a01234 into inossidabile:master May 29, 2016
@bogdanRada
Copy link
Contributor Author

awesome 😍 Thank you very much:)

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

Successfully merging this pull request may close these issues.

2 participants