-
Type: Task
-
Resolution: Done
-
Affects Version/s: None
-
Component/s: None
-
None
Hey Durran. I just noticed that a model's default scope will be applied if you use unscoped and then a scope. Eg:
class Porkchop include Mongoid::Document default_scope where(:default => true) scope :tasty, where(:tasty => true) end Porkchop.unscoped.tasty => #<Mongoid::Criteria selector: {:default=>true, :tasty=>true}, options: {}, class: Porkchop, embedded: false>
I'd expect Porkchop.unscoped.tasty not to contain the default scope.