diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-09-14 19:32:51 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-09-14 19:32:51 +0300 |
commit | c69b8e04591907d030b2cd544a606fd0e576116a (patch) | |
tree | 317db4259219bc7f3a3ff6e3c38c802a8d086d2c /app/finders/projects_finder.rb | |
parent | eb4a9bfbca5427e6b9a8fcf2ed0b1f9f96ae099d (diff) | |
download | gitlab-ce-c69b8e04591907d030b2cd544a606fd0e576116a.tar.gz |
Huge replace of old users_project and users_group references
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/finders/projects_finder.rb')
-rw-r--r-- | app/finders/projects_finder.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/app/finders/projects_finder.rb b/app/finders/projects_finder.rb index 26898bad493..222496cd317 100644 --- a/app/finders/projects_finder.rb +++ b/app/finders/projects_finder.rb @@ -19,10 +19,8 @@ class ProjectsFinder # Return ALL group projects group.projects else - projects_members = UsersProject.where( - project_id: group.projects, - user_id: current_user - ) + projects_members = ProjectMember.in_projects(group.projects). + with_user(current_user) if projects_members.any? # User is a project member |