diff options
author | Robert Speicher <robert@gitlab.com> | 2016-10-07 16:10:02 +0000 |
---|---|---|
committer | Robert Speicher <robert@gitlab.com> | 2016-10-07 16:10:02 +0000 |
commit | e565183ce6f0453db2ce88c9a4b508710fba0dc1 (patch) | |
tree | b6b9a31bab066c1f1e794c92898c5b8f70ba920e /app | |
parent | 212cf8f950610570d3d2fb946ea57defd6fc04f3 (diff) | |
parent | de61ebc8fcae9fbcd59ffdbd12ac91adc67079d3 (diff) | |
download | gitlab-ce-e565183ce6f0453db2ce88c9a4b508710fba0dc1.tar.gz |
Merge branch 'backport-part-of-ee-744' into 'master'
Make Member#add_user set access_level for requesters
## What does this MR do?
This is a backport of https://gitlab.com/gitlab-org/gitlab-ee/commit/c902d8d48409a4d46f7669fc5fc85b9ba86e71d6 from gitlab-org/gitlab-ee!744.
## Why was this MR needed?
This change is only used in EE right now, but there's no reason why it wouldn't be part of CE.
See merge request !6649
Diffstat (limited to 'app')
-rw-r--r-- | app/models/member.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/models/member.rb b/app/models/member.rb index 38a278ea559..b89ba8ecbb8 100644 --- a/app/models/member.rb +++ b/app/models/member.rb @@ -103,7 +103,12 @@ class Member < ActiveRecord::Base } if member.request? - ::Members::ApproveAccessRequestService.new(source, current_user, id: member.id).execute + ::Members::ApproveAccessRequestService.new( + source, + current_user, + id: member.id, + access_level: access_level + ).execute else member.save end |