weppos / breadcrumbs_on_rails

A simple Ruby on Rails plugin for creating and managing a breadcrumb navigation.
https://simonecarletti.com/code/breadcrumbs-on-rails
MIT License
944 stars 188 forks source link

rails 5 ActionController:API #82

Closed u007 closed 8 years ago

u007 commented 8 years ago

Hi,

when i tried to extend rails 5 new actioncontroller:api, i get breadcrumb error:

/usr/local/rvm/gems/ruby-2.2.2/gems/breadcrumbs_on_rails-2.3.1/lib/breadcrumbs_on_rails/action_controller.rb:16:in `block in <module:ActionController>': undefined method `helper' for ActionController::API:Class (NoMethodError)
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/activesupport/lib/active_support/concern.rb:120:in `class_eval'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/activesupport/lib/active_support/concern.rb:120:in `append_features'
    from /usr/local/rvm/gems/ruby-2.2.2/gems/breadcrumbs_on_rails-2.3.1/lib/breadcrumbs_on_rails/railtie.rb:14:in `include'
    from /usr/local/rvm/gems/ruby-2.2.2/gems/breadcrumbs_on_rails-2.3.1/lib/breadcrumbs_on_rails/railtie.rb:14:in `block (2 levels) in <class:Railtie>'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/activesupport/lib/active_support/lazy_load_hooks.rb:38:in `instance_eval'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/activesupport/lib/active_support/lazy_load_hooks.rb:38:in `execute_hook'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/activesupport/lib/active_support/lazy_load_hooks.rb:45:in `block in run_load_hooks'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/activesupport/lib/active_support/lazy_load_hooks.rb:44:in `each'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/activesupport/lib/active_support/lazy_load_hooks.rb:44:in `run_load_hooks'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/actionpack/lib/action_controller/api.rb:144:in `<class:API>'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/actionpack/lib/action_controller/api.rb:87:in `<module:ActionController>'
    from /usr/local/rvm/gems/ruby-2.2.2/bundler/gems/rails-d3150c81061f/actionpack/lib/action_controller/api.rb:5:in `<top (required)>'
    from /var/www/project/app/controllers/mobile_application_controller.rb:1:in `<top (required)>'
weppos commented 8 years ago

Duplicates #77