mirror of
https://github.com/discourse/discourse.git
synced 2025-05-28 13:51:18 +08:00
FEATURE: Make allow_uploaded_avatars accept TL (#14091)
This gives admins more control over who can upload custom profile pictures.
This commit is contained in:
@ -1138,7 +1138,7 @@ class UsersController < ApplicationController
|
||||
|
||||
if type.blank? || type == 'system'
|
||||
upload_id = nil
|
||||
elsif !SiteSetting.allow_uploaded_avatars
|
||||
elsif !TrustLevelAndStaffAndDisabledSetting.matches?(SiteSetting.allow_uploaded_avatars, user)
|
||||
return render json: failed_json, status: 422
|
||||
else
|
||||
upload_id = params[:upload_id]
|
||||
|
Reference in New Issue
Block a user