Class: SqlValues::Railtie

Inherits:
Rails::Railtie
  • Object
show all
Defined in:
lib/sql_values/railtie.rb,
lib/sql_values/railtie.rb

Class Method Summary collapse

Class Method Details

.insertObject



16
17
18
19
20
21
# File 'lib/sql_values/railtie.rb', line 16

def self.insert
  if defined?(ActiveRecord)
    ActiveRecord::Relation.send(:include, SqlValues::RelationInstanceMethods)
    ActiveRecord::Base.extend(SqlValues::ActiveRecordClassMethods)
  end
end