RocketChat / RocketChat/Rocket.Chat
setAvatarFromService failed when Accounts_AllowUserAvatarChange == false
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 46.1k
- Forks
- 13.9k
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 130
Description
Description:
When Accounts_AllowUserAvatarChange is set to false, user registration from OAuth2 has no avatar.
Steps to reproduce:
- A new user click OAuth2 login button
Expected behavior:
Login success
User has avatar from OAuth2 identity info
Actual behavior:
Login failed, popup shows "Not Allowed"
Login again success
User has no avatar
Server Setup Information:
- Version of Rocket.Chat Server: 1.1.1
Relevant logs:
WebSocket log:
{"msg":"result","id":"3","error":{"isClientSafe":true,"error":"error-not-allowed","reason":"Not allowed","details":{"method":"setAvatarFromService"},"message":"Not allowed [error-not-allowed]","errorType":"Meteor.Error"}}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the setAvatarFromService method used during OAuth2 registration, with Accounts_AllowUserAvatarChange set to false, and compare the failed WebSocket call with the successful second login. Confirm that registration succeeds and the avatar from the OAuth2 identity info is retained without the error-not-allowed response.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- authentication
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100