diff --git a/db/migrate/20150120140346_refactor_roles.rb b/db/migrate/20150120140346_refactor_roles.rb index c2e820288..eaa84db33 100644 --- a/db/migrate/20150120140346_refactor_roles.rb +++ b/db/migrate/20150120140346_refactor_roles.rb @@ -3,9 +3,7 @@ class RefactorRoles < ActiveRecord::Migration add_column :users, :roles, :string, array: true User.all.each do |x| - r = x.role - next unless r - x.roles = [r.code] + x.roles = ['admin'] x.save end