Make Member#add_user set access_level for requesters

Signed-off-by: Rémy Coutable <remy@rymai.me>
This commit is contained in:
Rémy Coutable 2016-10-03 11:06:52 +02:00
parent 7134599860
commit de61ebc8fc

View file

@ -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