Commit cb6f9c1af4cb662c41c28cd8eb0b7fa37e886cda
1 parent
ac8f7163
Exists in
theme-brasil-digital-from-staging
and in
9 other branches
Fix profile role verification
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
app/models/profile.rb
@@ -73,7 +73,7 @@ class Profile < ActiveRecord::Base | @@ -73,7 +73,7 @@ class Profile < ActiveRecord::Base | ||
73 | find_role('editor', env_id) | 73 | find_role('editor', env_id) |
74 | end | 74 | end |
75 | def self.organization_member_roles(env_id) | 75 | def self.organization_member_roles(env_id) |
76 | - all_roles(env_id).select{ |r| r.key.match(/^profile_/) unless r.key.blank? || !r.profile_id.nil?} | 76 | + all_roles(env_id).select{ |r| r.key.match(/^profile_/) unless r.key.blank? } |
77 | end | 77 | end |
78 | def self.all_roles(env_id) | 78 | def self.all_roles(env_id) |
79 | Role.all :conditions => { :environment_id => env_id } | 79 | Role.all :conditions => { :environment_id => env_id } |