title: undefined method `friendly' for #<ActiveRecord::Relation []>
body: <p>I recently installed <code>friendly_id</code> 5 on my Rails 4 app. I've followed the quick start guide, and setup a model like this:</p>
  
  <pre><code>class Official::Master &lt; Official
    extend FriendlyId
    friendly_id :name, use: [:slugged, :history]
  
  end
  </code></pre>
  
  <p>When I try to save an Official::Master, however, I get this error:</p>
  
  <pre><code>undefined method `friendly' for #&lt;ActiveRecord::Relation []&gt;
  </code></pre>
  
  <p>This happens in the <code>create</code> controller action:</p>
  
  <pre><code>def create
    official = Official::Master.new(official_params)
    official.save # error occurs on this line
  end
  </code></pre>
  
  <p>Unfortunately, Rails isn't producing a stack trace, which it typically does. I'm at a loss for how to troubleshoot this error.</p>
  
  <p>UPDATE:</p>
  
  <p>Removed the backtrace silencers and got this:</p>
  
  <blockquote>
    <p>activerecord (4.0.1) lib/active_record/relation/delegation.rb:121:in
    <code>method_missing' activerecord (4.0.1)
    lib/active_record/relation/delegation.rb:68:in</code>method_missing'
    friendly_id (5.0.1) lib/friendly_id/slugged.rb:302:in
    <code>scope_for_slug_generator' friendly_id (5.0.1)
    lib/friendly_id/history.rb:104:in</code>scope_for_slug_generator'
    friendly_id (5.0.1) lib/friendly_id/slugged.rb:313:in <code>slug_generator'
    friendly_id (5.0.1) lib/friendly_id/slugged.rb:294:in</code>set_slug'</p>
  </blockquote>
  
  <p>Looks like the error is on line 302 of slugged.rb:</p>
  
  <pre><code>scope = scope.friendly unless friendly_id_config.uses? :finders
  </code></pre>