Module: Gricer::ActiveModel::Request::ClassMethods

Defined in:
lib/gricer/active_model/request.rb

Instance Method Summary collapse

Instance Method Details

#only_first_in_sessionActiveRecord::Relation/Mongoid::Criteria

Filter out anything that has not the first_in_session flag

Returns:

  • (ActiveRecord::Relation/Mongoid::Criteria)


17
18
19
# File 'lib/gricer/active_model/request.rb', line 17

def only_first_in_session
  where(is_first_in_session: true)
end