files in lib directory not loading

Hi there

I'm trying to install this rack application:

However, my rails3 setup is not picking up my lib file:


which contains:

  module Rack
    class FirebugLogger

And in my config/environments/development.rb :

  App::Application.configure do
    config.middleware.use Rack::FirebugLogger

But rails3 is not finding my lib file :frowning:

  uninitialized constant Rack::FirebugLogger (NameError)

Any clues?


Is "app/lib/rack/firebug_logger.rb" simply the wrong direcotry?

Or is there something I need to do to make it work?

If I put....

  module Rack
    class FirebugLogger

... inside my application controller it all works fine --
Rack::FirebugLogger is accessible and works.

thanks for any advice

Does anyone have any clues of suggestions?

I'm not even sure how to manually load Rack::Firebugger in "app/lib/

But would rather it just automatically loaded

There is a typo on the blog post you referred to. It should go in lib/
not app/lib.

Also from the same post:
"Rails autoloads (and namespaces) any code placed in the lib directory,
so that is where we’ll place our FirebugLogger code."