Commit 5bc38ff7 authored by Heinrich Lee Yu's avatar Heinrich Lee Yu Committed by Douglas Barbosa Alexandre

Fix double wrapping of members in a presenter

We use `present_members` here so that associations are preloaded.
We do this even if there's only one record here because it raises
an exception when user.status isn't preloaded.
parent 740115d9
......@@ -21,9 +21,9 @@ module MembershipActions
member = Members::UpdateService
.new(current_user, update_params)
.execute(member)
.present(current_user: current_user)
present_members([member])
member = present_members([member]).first
respond_to do |format|
format.js { render 'shared/members/update', locals: { member: member } }
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment