title: Getting error uninitialized constant NHLSDecorator if config.eager_load = false
body: <p>I am new to Rails and working on Rails 4 application. In my development.rb I have</p>
  
  <pre><code>config.cache_classes = false 
  config.eager_load = false 
  </code></pre>
  
  <p>Here is the directory structure of my application</p>
  
  <p><a href="https://i.stack.imgur.com/uInqf.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uInqf.png" alt="enter image description here"></a></p>
  
  <p>Here is the snippet of my NHLSDecorator class</p>
  
  <p><a href="https://i.stack.imgur.com/7J7M1.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/7J7M1.png" alt="NHLSDecorator class"></a></p>
  
  <p>Here is the line from the _results_html.erb file that when run raise error</p>
  
  <pre><code>&lt;% posting = Posting::Decorator.new(posting) %&gt;
  </code></pre>
  
  <p>Now with this I am getting error that </p>
  
  <p><a href="https://i.stack.imgur.com/o6B7M.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/o6B7M.png" alt="Error"></a></p>
  
  <p>I also have <code>nhls/app/presenters</code> directory in my autopath. I also added <code>app/presenters/posting</code> directory. Here is the snapshot of my application.rb file</p>
  
  <pre><code># Custom directories with classes and modules you want to be autoloadable.
  config.autoload_paths += %W(#{config.root}/extras)
  config.autoload_paths += %W(#{config.root}/lib)
  config.autoload_paths += Dir["#{config.root}/lib/**/"]
  config.autoload_paths += Dir["#{config.root}/app/controllers/**/"]
  config.autoload_paths += Dir["#{config.root}/app/reports/**/"]
  config.autoload_paths += Dir["#{config.root}/app/searchers/**/"]
  config.autoload_paths += Dir["#{config.root}/app/workers/**/"]
  config.autoload_paths += %W(#{config.root}/app/models/ckeditor)
  config.autoload_paths += %W(#{config.root}/app/presenters/posting)
  </code></pre>
  
  <p>But I am getting the error. If I change <code>config.eager_load = true</code>. Then it works fine. Why I am getting this error? What can be the cause?</p>
  
  <p>Thanks</p>