Method: ActiveRecord::Relation#create!
- Defined in:
- lib/ocean-dynamo/active_record_stuff/relation.rb
#create!(*args, &block) ⇒ Object
Similar to #create, but calls create! on the base class. Raises an exception if a validation error occurs.
Expects arguments in the same format as Base.create!.
126 127 128 |
# File 'lib/ocean-dynamo/active_record_stuff/relation.rb', line 126 def create!(*args, &block) scoping { @klass.create!(*args, &block) } end |