0

To include httparty in my rails 4.0.0 app, in my gemfile I wrote:

gem 'httparty'

and then ran bundle install

Next in my application.rb file, I inserted this:

module myApp
  class Application < Rails::Application
    ### ---
    config.gem "httparty"
    ### ---
end

Now when I load rails c and do a require "httparty", I get false

What am I doing wrong? How do I load httparty in my rails app?

Amit Erandole
  • 11,995
  • 23
  • 65
  • 103
  • 1
    But does it work? I can `require 'nokogiri'` from `irb` and get `true`, `require 'set'` says `false` but they both work. And both `require`s say false from the Rails console but they both still work there too. – mu is too short Jul 08 '13 at 05:43
  • Sorry it does work - was using the caps wrong -eeps – Amit Erandole Jul 08 '13 at 05:54

1 Answers1

2

It's already loaded by Rails. You also don't need the config.gem in application.rb

Try using HTTParty from the console. It should just work.

svs
  • 2,425
  • 1
  • 14
  • 10