module Mongoid::Extensions::Symbol::ClassMethods

def demongoize(object)

Other tags:
    Since: - 3.0.0

Returns:
  • (Symbol) - The object.

Parameters:
  • object (Object) -- The object to demongoize.

Other tags:
    Example: Demongoize the object. -
def demongoize(object)
  object.try(:to_sym)
end

def mongoize(object)

Other tags:
    Since: - 3.0.0

Returns:
  • (Symbol) - The object mongoized.

Parameters:
  • object (Object) -- The object to mongoize.

Other tags:
    Example: Mongoize the object. -
def mongoize(object)
  demongoize(object)
end