Topic-icon Avatar missing after switching to Amazon S3 for JomSocial

10 years 9 months ago - 10 years 9 months ago #39235 by fb_677898977
As the description says the avatar no longer appears once a user is logged in with SCLogin. Worked fine before I switched JomSocial to use Amazon S3 for storage. The avatars appear fine in jReviews for articles and also on everyone's profile in the the JomSocial activity feed. Any idea why it isn't working in SCLogin?

Thanks!

site: www.barkleyandpaws.com
Last edit: 10 years 9 months ago by fb_677898977.
The topic has been locked.
Support Specialist
What avatar is missing? Do you mean the one that shows in the SCLogin area once a user is logged in... or is the avatar not being pulled into to JomSocial when the user logs in with JFBConnect?

My guess is the first, and we'll look into that and let you know what we find. It's possible we're not properly detecting and showing S3 avatars and just always assuming they're local.

Thanks,
Alex
The topic has been locked.
Yes the first one... Once a user logs in the avatar that displays in the SCLogin module no longer displays the user's avatar. Worked before I moved the JomSocial avatars to S3.

Thanks!
The topic has been locked.
Just checking in to see if you ever figured this one out... thanks!
The topic has been locked.
Support Specialist
Mark,
Sorry for the delay. We've been trying to recreate and understand the issues, but actually ran into some silliness with Amazon S3. We think we know what needs to change though, if you're interested in trying. It should, hopefully, be a simple fix. If you're up for it, edit the /modules/mod_sclogin/helper.php file. Around line 220, you'll see:
$jsUser = & CFactory::getUser($user->id);
            $avatarURL = $jsUser->get('_avatar');
Update that last line to:
$avatarURL = $jsUser->getThumbAvatar();
Hopefully, that's all there is to it. If not, or you run into other issues, just let me know.

Thanks,
Alex
The topic has been locked.
Thanks! That almost works! The avatar indeed now displays but it is very pixelated. Looks like it is trying to take a smaller size and expand it to fit...
The topic has been locked.
Support Specialist
Try changing getThumbAvatar to getAvatar. Let me know how that goes, and we'll try to get that update into the next release, scheduled for this Friday.

Thanks for your patience and feedback!
Alex
The topic has been locked.
That worked! Thanks!
The topic has been locked.
Support Specialist
Awesome! Thanks for the feedback. We included that fix in the next release, hopefully due out on Friday. You shouldn't have to worry about that again going forward.

If you need anything else, just let us know.

Thanks,
Alex
The topic has been locked.