Sha256: f328ed5ce7d9f05fb4267aac286084545cd026be28e01f02772e003bfeac6ae1
Contents?: true
Size: 510 Bytes
Versions: 2
Compression:
Stored size: 510 Bytes
Contents
module RelationToStruct::ActiveRecordBaseExtension module ClassMethods def _sanitize_sql_for_relation_to_struct(sql) sanitized_sql = ActiveRecord::VERSION::MAJOR >= 5 ? sanitize_sql(sql) : sanitize_sql(sql, nil) end delegate( :structs_from_sql, :pluck_from_sql, :value_from_sql, :tuple_from_sql, :run_sql, :to => :connection ) end end ::ActiveRecord::Base.singleton_class.send(:prepend, RelationToStruct::ActiveRecordBaseExtension::ClassMethods)
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
relation_to_struct-1.7.0 | lib/relation_to_struct/active_record_base_extension.rb |
relation_to_struct-1.6.0 | lib/relation_to_struct/active_record_base_extension.rb |