➜ example-app git:(master) ✗ rake c2:discover
rake aborted!
Problem:
Defining a scope of value {:where=>{:enabled=>true}} on C2::Informant::FormElement is not allowed.
Summary:
Scopes in Mongoid must be either criteria objects or procs that wrap criteria objects.
Resolution:
Change the scope to be a criteria or proc wrapped critera.
Example:
class Band
include Mongoid::Document
field :active, type: Boolean, default: true
scope :active, where(active: true)
scope :inactive, ->{ where(active: false) }
end
Tasks: TOP => c2:discover
(See full trace by running task with --trace)