Module: Omnidata::Orm

Extended by:
ActiveSupport::Concern
Defined in:
lib/omnidata/orm.rb

Defined Under Namespace

Modules: ClassMethods

Instance Method Summary collapse

Instance Method Details

#new_record?Boolean

Returns:

  • (Boolean)


11
12
13
14
15
# File 'lib/omnidata/orm.rb', line 11

def new_record?
  self.id.nil?
rescue
  true
end