Skip to content

Commit

Permalink
Updated username migration to create a unique index on username
Browse files Browse the repository at this point in the history
  • Loading branch information
baileylo committed Mar 4, 2011
1 parent 513c7b0 commit febba49
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions db/migrate/20110304082836_add_username_to_user.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
class AddUsernameToUser < ActiveRecord::Migration
def self.up
add_column :users, :username, :string
add_index :users, :username, :unique => true
end

def self.down
Expand Down

0 comments on commit febba49

Please sign in to comment.