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

undefined method `content_tag' #354

Closed
Amnesthesia opened this issue Apr 9, 2015 · 13 comments
Closed

undefined method `content_tag' #354

Amnesthesia opened this issue Apr 9, 2015 · 13 comments

Comments

@Amnesthesia
Copy link

No matter what I do, it seems that as soon as I click to view the details of any resource, I get this error.

undefined method `content_tag' for #Apipie::ApipiesController:0x007fecd8cd6ff0

I'm on Ruby 2.1.4 and Rails 4.2.1

Extracted source (around line #4):

  def heading(title, level=1)
    content_tag("h#{level}") do
      title
    end
  end

Top stack trace:

  1. apipie-rails (0.3.4) app/helpers/apipie_helper.rb:4:in `heading'
  2. actionpack (4.2.1) lib/abstract_controller/helpers.rb:67:in `heading'
  3. apipie-rails (0.3.4) app/views/apipie/apipies/_method_detail.erb:4:in `__home_amnesthesia__rvm_gems_ruby________ow_n_gems_apipie_rails_______app_views_apipie_4. apipies__method_detail_erb___4240183086102969573_60079080'
  4. actionview (4.2.1) lib/action_view/template.rb:145:in `block in render'
  5. activesupport (4.2.1) lib/active_support/notifications.rb:166:in `instrument'
  6. actionview (4.2.1) lib/action_view/template.rb:333:in `instrument'
  7. actionview (4.2.1) lib/action_view/template.rb:143:in `render'
  8. actionview (4.2.1) lib/action_view/renderer/partial_renderer.rb:339:in `render_partial'
@saneshark
Copy link
Contributor

@Amnesthesia you are not alone: see: #350

You might be ok if you drop down to 0.3.3 in the interim.

@Seralto
Copy link

Seralto commented Apr 29, 2015

Same problem.

@waleedasif322
Copy link

Try putting the latest version in your Gemfile using github, the problem was fixed for me like this:
gem 'apipie-rails', :github => 'Apipie/apipie-rails'

@Seralto
Copy link

Seralto commented Apr 30, 2015

Great waleedasif322, problem solved ;)

@FPierre
Copy link

FPierre commented Jun 19, 2015

Same problem, same solution (gem 'apipie-rails', :github => 'Apipie/apipie-rails')

@ghost
Copy link

ghost commented Jun 19, 2015

@FPierre It's better to specify revision that has this fix and nothing more. You don't want to get unexpected changes after running bundle udpate, right?

gem 'apipie-rails', github: 'Apipie/apipie-rails', ref: '928bd858fd14ec67eeb9483ba0d43b3be8339608'

@jasonswett
Copy link

I was having the same problem on Rails 3.2 and was able to get it working with commit a74f196f99fb33612c3e4982ade3077ab663a510.

@brunojppb
Copy link

@IlyaBylich +1

@jayelkaake
Copy link

+1 - Thanks guys!

@wesf90
Copy link

wesf90 commented Sep 2, 2015

I hate to +1 again, but this was an excellent solution to this tricky problem. Thanks @iliabylich

@lucasecf
Copy link

lucasecf commented Sep 3, 2015

@IlyaBylich +1

@Thomsen
Copy link

Thomsen commented Sep 13, 2015

@iliabylich +1 Thanks!

gem uninstall apipie-rails
bundle install

@ChristianWolfJohannsen
Copy link

This and #396 appear to be fixed with PR #350 and included in release 0.3.5 on October 21.
Please close these issues.

@Pajk Pajk closed this as completed Dec 13, 2015
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

No branches or pull requests