title: Concern is not loading in Rails 5
body: <p>I have a basic Rails application and I am trying to use concerns for drying models. Everything goes fine in the development environment, but when I try to upload the app to Heroku, it constantly gives me this error: </p>
  
  <pre><code>/app/app/models/address.rb:3:in `&lt;class:Address&gt;': uninitialized constant Address::Persistable (NameError)
  </code></pre>
  
  <p>I tried to disable eager loading, but it didn't help.</p>
  
  <p>Here is my Address Model:</p>
  
  <pre><code>class Address &lt; ApplicationRecord
  
    include Persistable
  
    belongs_to :city
    belongs_to :company
  
    validates :city_id, :human, :lat, :lng, presence: true
  end
  </code></pre>
  
  <p>And here is the module that I named "persistable", located at <code>app/models/concerns/persistable.rb</code></p>
  
  <pre><code>module Persistable
    extend ActiveSupport::Concern
  
    included do
      scope :historical, -&gt; { where(is_historical: true) }
      scope :deleted, -&gt; { where(is_deleted: true) }
      default_scope { where(is_historical: false, is_deleted: false) }
  
      def delete
        update_attribute(:is_deleted, true)
      end
  
      def archive
        update_attribute(:is_historical, true)
      end
  
      def revive
        update_attribute(:is_historical, false)
        update_attribute(:is_deleted, false)
      end
    end
  end
  </code></pre>
  
  <p>What I already did:</p>
  
  <ul>
  <li>tried to switch off eager loading</li>
  <li>tried to move the <code>Persistable</code> module out of the <code>concerns</code> directory</li>
  <li>tried to include the <code>concerns</code> path to the autoload configuration</li>
  </ul>
  
  <p>Nothing worked, I still have this problem!</p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>I did command form <a href="http://guides.rubyonrails.org/autoloading_and_reloading_constants.html" rel="nofollow noreferrer">guide</a> <code>rails r 'puts ActiveSupport::Dependencies.autoload_paths'</code> to check autoload_paths and I got:</p>
  
  <pre><code>D:/work/rails/www/app/models/concerns
  D:/work/rails/www/app/assets
  D:/work/rails/www/app/channels
  D:/work/rails/www/app/controllers
  D:/work/rails/www/app/helpers
  D:/work/rails/www/app/jobs
  D:/work/rails/www/app/mailers
  D:/work/rails/www/app/models
  D:/work/rails/www/test/mailers/previews
  </code></pre>