Module: Mongoid::Extensions::Object::Reflections

Extended by:
ActiveSupport::Concern
Included in:
Object
Defined in:
lib/mongoid/extensions/object/reflections.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#ivar(name) ⇒ Object



8
9
10
11
12
13
# File 'lib/mongoid/extensions/object/reflections.rb', line 8

def ivar(name)
  if instance_variable_defined?("@#{name}")
    return instance_variable_get("@#{name}")
  end
  nil
end