Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow mods and admins to see all profile bios #11005

Merged
merged 1 commit into from
Apr 12, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions app/views/users/profile.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,13 @@

<div class="offset-md-1 order-first order-md-last col-md-4 text-center">
<div class="text-center d-none d-lg-block">
<%if @content_approved or (!current_user.nil? && current_user.id == @profile_user.id)%>
<%if @content_approved || (!current_user.nil? && current_user.id == @profile_user.id) || logged_in_as(['admin', 'moderator']) %>
<%= image_tag(@profile_user.profile_image, class:'rounded-circle', id:'profile-photo', style:"width:50%;margin-bottom:10px;") %>
<%end%>
<h4 class="mt-3"><strong>@<%= @profile_user.name %> <%= @profile_user.new_contributor %></strong></h4>
</div>
<div style="text-align:center;" class="d-lg-none">
<%if @content_approved or (!current_user.nil? && current_user.id == @profile_user.id)%>
<%if @content_approved || (!current_user.nil? && current_user.id == @profile_user.id) || logged_in_as(['admin', 'moderator']) %>
<%= image_tag(@profile_user.profile_image(:medium), class:'rounded-circle', id:'profile-photo', style:"width:50%;margin-bottom:20px;") %>
<%end%>
<h4 class="mt-3"><strong>@<%= @profile_user.name %> <%= @profile_user.new_contributor %></strong></h4>
Expand Down