Module: Sequel::Plugins::ClassTableInheritance::InstanceMethods

Defined in:
lib/sequel/plugins/class_table_inheritance.rb

Instance Method Summary collapse

Instance Method Details

#deleteObject

Delete the row from all backing tables, starting from the most recent table and going through all superclasses.

Raises:



290
291
292
293
294
295
296
# File 'lib/sequel/plugins/class_table_inheritance.rb', line 290

def delete
  raise Sequel::Error, "can't delete frozen object" if frozen?
  model.cti_models.reverse_each do |m|
    cti_this(m).delete
  end
  self
end