tap/db/migrate/20190408122720_add_api_token.rb
2019-04-08 17:01:26 +02:00

10 lines
185 B
Ruby

class AddApiToken < ActiveRecord::Migration
def change
add_column :users, :userkey, :string
User.all.each do |user|
user.generate_key
user.save
end
end
end