forked from Gitlink/forgeplus
fix
This commit is contained in:
parent
495d7773fe
commit
0f45e8f44b
|
@ -775,7 +775,8 @@ class ApplicationController < ActionController::Base
|
|||
end
|
||||
|
||||
def convert_image!
|
||||
@image = params[:image] || user_params[:image]
|
||||
@image = params[:image]
|
||||
@image = @image.nil? && params[:user].present? ? params[:user][:image] : @image
|
||||
return unless @image.present?
|
||||
max_size = EduSetting.get('upload_avatar_max_size') || 2 * 1024 * 1024 # 2M
|
||||
if @image.class == ActionDispatch::Http::UploadedFile
|
||||
|
|
Loading…
Reference in New Issue