From 350ae6cdc1ea83e21c23abd10e7e99c9a0bbdbd2 Mon Sep 17 00:00:00 2001 From: schneems Date: Thu, 7 Jan 2016 17:12:58 -0600 Subject: Use `key` as primary key in schema. --- activerecord/lib/active_record/internal_metadata.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/lib') diff --git a/activerecord/lib/active_record/internal_metadata.rb b/activerecord/lib/active_record/internal_metadata.rb index e907bd0563..fc1bb0bdce 100644 --- a/activerecord/lib/active_record/internal_metadata.rb +++ b/activerecord/lib/active_record/internal_metadata.rb @@ -35,7 +35,7 @@ module ActiveRecord # Creates a internal metadata table with columns +key+ and +value+ def create_table unless table_exists? - connection.create_table(table_name, id: false) do |t| + connection.create_table(table_name, primary_key: :key, id: false ) do |t| t.column :key, :string t.column :value, :string t.timestamps -- cgit v1.2.3