diff options
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20170419144536_add_view_messages_to_all_existing_roles.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/db/migrate/20170419144536_add_view_messages_to_all_existing_roles.rb b/db/migrate/20170419144536_add_view_messages_to_all_existing_roles.rb new file mode 100644 index 000000000..d010ba497 --- /dev/null +++ b/db/migrate/20170419144536_add_view_messages_to_all_existing_roles.rb @@ -0,0 +1,9 @@ +class AddViewMessagesToAllExistingRoles < ActiveRecord::Migration + def up + Role.all.each { |role| role.add_permission! :view_messages } + end + + def down + # nothing to revert + end +end |