mirror of
https://github.com/discourse/discourse.git
synced 2025-09-06 10:50:21 +08:00
FIX: hide restricted profile info from TL0 users to anonymous in 'JS-off' page
This commit is contained in:
parent
65c106325c
commit
07211489f0
4 changed files with 18 additions and 5 deletions
|
@ -30,6 +30,7 @@ class UsersController < ApplicationController
|
|||
user_serializer = UserSerializer.new(@user, scope: guardian, root: 'user')
|
||||
respond_to do |format|
|
||||
format.html do
|
||||
@restrict_fields = guardian.restrict_user_fields?(@user)
|
||||
store_preloaded("user_#{@user.username}", MultiJson.dump(user_serializer))
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue