h[project_id] = memberships.where(:project_id => project_id)[0]
This commit is contained in:
parent
253d2523d8
commit
0e8e39ee8c
|
@ -830,7 +830,8 @@ class User < Principal
|
|||
project_id = project.is_a?(Project) ? project.id : project
|
||||
|
||||
@membership_by_project_id ||= Hash.new {|h, project_id|
|
||||
h[project_id] = memberships.where(:project_id => project_id).first
|
||||
# h[project_id] = memberships.where(:project_id => project_id).first
|
||||
h[project_id] = memberships.where(:project_id => project_id)[0]
|
||||
}
|
||||
@membership_by_project_id[project_id]
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue