v0.16.3 Profile image handling improvement
This commit is contained in:
parent
b38e2853bb
commit
c384aebed5
@ -1,5 +1,5 @@
|
||||
# gossamer threads migration-import code
|
||||
# v0.16.2
|
||||
# v0.16.3
|
||||
|
||||
require 'mysql2'
|
||||
require 'open-uri'
|
||||
@ -480,7 +480,8 @@ class GossamerForumsImporter < ImportScripts::Base
|
||||
next if resized_upload.nil?
|
||||
|
||||
# Ensure the upload ID is valid and exists
|
||||
if resized_upload && UserAvatar.exists?(custom_upload_id: resized_upload.id)
|
||||
if resized_upload
|
||||
# && UserAvatar.exists?(custom_upload_id: resized_upload.id)
|
||||
# Set the avatar using the resized image
|
||||
user.user_avatar = UserAvatar.create!(user_id: user.id, custom_upload_id: resized_upload.id)
|
||||
user.save!
|
||||
|
Loading…
Reference in New Issue
Block a user