remove trailing white-spaces from db/migrate/20101104182107_add_unique_index_on_members.rb (#9510)

Contributed by Igor Zubkov.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7760 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2011-11-09 08:47:57 +00:00
parent 02378acc80
commit f1cc1943df
1 changed files with 1 additions and 1 deletions

View File

@ -11,7 +11,7 @@ class AddUniqueIndexOnMembers < ActiveRecord::Migration
" WHERE m.id > (SELECT min(m1.id) FROM #{Member.table_name} m1 WHERE m1.user_id = m.user_id AND m1.project_id = m.project_id)").each do |i| " WHERE m.id > (SELECT min(m1.id) FROM #{Member.table_name} m1 WHERE m1.user_id = m.user_id AND m1.project_id = m.project_id)").each do |i|
Member.delete_all(["id = ?", i]) Member.delete_all(["id = ?", i])
end end
# Then add a unique index # Then add a unique index
add_index :members, [:user_id, :project_id], :unique => true add_index :members, [:user_id, :project_id], :unique => true
end end