Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

update seed for superuser role

  • Loading branch information...
commit 2115e5b3488a52745e2b045ed7cb1384ef4f07cc 1 parent 926fe1c
progressbarsk authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  db/seeds/registrations.rb
View
2  db/seeds/registrations.rb
@@ -1,6 +1,6 @@
if defined?(User)
User.all.each do |user|
- if user.plugins.where(:name => 'registrations').blank?
+ if user.has_role?(:superuser) && user.plugins.where(:name => 'registrations').blank?
user.plugins.create(:name => 'registrations',
:position => (user.plugins.maximum(:position) || -1) +1)
end
Please sign in to comment.
Something went wrong with that request. Please try again.