mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 03:31:13 +08:00
FIX: avatar was attached to the user who uploaded it...
This commit is contained in:
@ -970,7 +970,7 @@ describe UsersController do
|
||||
upload = Fabricate(:upload)
|
||||
Upload.expects(:create_for).returns(upload)
|
||||
# enqueues the avatar generator job
|
||||
Jobs.expects(:enqueue).with(:generate_avatars, { upload_id: upload.id })
|
||||
Jobs.expects(:enqueue).with(:generate_avatars, { user_id: user.id, upload_id: upload.id })
|
||||
xhr :post, :upload_avatar, username: user.username, file: avatar
|
||||
user.reload
|
||||
# erase the previous template
|
||||
|
Reference in New Issue
Block a user