Module: Mongoid::Document

Included in:
ActionDispatch::Session::MongoidStore::Session
Defined in:
lib/locomotive/mongoid/patches.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#as_json(options = {}) ⇒ Object



8
9
10
11
12
# File 'lib/locomotive/mongoid/patches.rb', line 8

def as_json(options = {})
  attrs = super(options)
  attrs["id"] = attrs["_id"]
  attrs
end