aboutsummaryrefslogblamecommitdiffstats
path: root/activerecord/lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
blob: c9855019c1804fc6d4f8861e9cf580864a0ada99 (plain) (tree)
1
2
3
4
5
6
7
8
9
10

                             


                           
                                                                               



                                                 
 


                                                          
             



         
# frozen_string_literal: true

module ActiveRecord
  module ConnectionAdapters
    module SQLite3
      class TableDefinition < ActiveRecord::ConnectionAdapters::TableDefinition
        def references(*args, **options)
          super(*args, type: :integer, **options)
        end
        alias :belongs_to :references

        private
          def integer_like_primary_key_type(type, options)
            :primary_key
          end
      end
    end
  end
end