كيفية إجبار تحديث الصورة الرمزية باستخدام SSO؟

أستخدم SSO وأمرر هذا المصفوفة عند تسجيل دخول المستخدم:

// وأخيرًا نبني المصفوفة الكبيرة التي نمررها إلى discourse
$userParams = [
	'external_id'         => $userObject->getID(),
	'email'               => $userObject->getEmail(),
	'username'            => $name,
	'avatar_url'          => $forumThumbURL,
	'avatar_force_update' => 'true',
	'groups'              => implode(',', $groupsArray),
];

إليك المشكلة: الصورة الرمزية (الأفاتار) لا يتم تحديثها أبدًا. فأنا عالق مع صورة رمزية قديمة على الموقع ولا يبدو أنها ستتغير. يمكنني تسجيل الدخول والخروج، وأنا أعلم أن هذا الكود يُستدعى، لكن لا يحدث أي تغيير. طابور Sidekiq الخاص بي فارغ (عند 0).

هل هذا الأمر مخصص لمستخدم مسؤول؟ هل قد يكون لذلك أي تأثير؟

The parameters you are passing look correct to me. It should not make any difference that you are trying to set the avatar for an admin user. Are you sure that the avatar_url you are passing is correct? If you try logging in as a new user, does the avatar get set correctly?

Hey, thanks for the reply. So I tried this with a different user – and for that user it’s working. But for my admin user, no go, it won’t let go of the image it has.

I realized that the image for my admin is the one it downloaded from Gravatar (when I first set up my forum), and since then I’ve completely turned off Gravatar. But could that have something to do with why it won’t let it go?