]> git.openstreetmap.org Git - rails.git/blobdiff - db/migrate/20140507110937_create_changeset_comments.rb
Standardise on double quoted strings
[rails.git] / db / migrate / 20140507110937_create_changeset_comments.rb
index a44fd61ceb7ba2ea098017bcc393dcf58525008d..26c257cbc4476b7fc4461c5732fe7d64c24456f7 100644 (file)
@@ -1,4 +1,4 @@
-require 'migrate'
+require "migrate"
 
 class CreateChangesetComments < ActiveRecord::Migration
   def change
@@ -9,8 +9,10 @@ class CreateChangesetComments < ActiveRecord::Migration
       t.timestamp :created_at, :null => false
       t.boolean :visible, :null => false
     end
-    add_foreign_key :changeset_comments, [:changeset_id], :changesets, [:id]
-    add_foreign_key :changeset_comments, [:author_id], :users, [:id]
+
+    add_foreign_key :changeset_comments, :changesets, :name => "changeset_comments_changeset_id_fkey"
+    add_foreign_key :changeset_comments, :users, :column => :author_id, :name => "changeset_comments_author_id_fkey"
+
     add_index :changeset_comments, :created_at
   end
 end