You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Internal] Room - Room chat avatar is different for user who creates room & who has been invited to room #33470
Version Number: 1.4.15-4 Reproducible in staging?: Y Reproducible in production?: Y If this was caught during regression testing, add the test name, ID and link from TestRail: Email or phone of affected tester (no customers): Logs:https://stackoverflow.com/c/expensify/questions/4856 Expensify/Expensify Issue URL: Issue reported by: Applause - Internal Team Slack conversation:
Action Performed:
Launch app
Tap fab--start chat
Tap room
Enter room name and select a workspace with custom avatar
Tap create room
Tap header
Tap members---Invite
Invite user X to room
9 .Navigate to LHN and note avatar of room chat
changed the title [-]Room - Room chat avatar is different for user who creates room & who has been invited to room[/-][+][$500] Room - Room chat avatar is different for user who creates room & who has been invited to room[/+]on Dec 22, 2023
Please re-state the problem that we are trying to solve in this issue.
Room chat avatar is different for user who creates room & who has been invited to room
What is the root cause of that problem?
The root cause is that the user who has been invited to room doesn't have the policy data about workspace in Onyx so that the default workspace avatar will be showed.
This issue only happens when we invite the user who isn't member of this workspace to the only room.
Please re-state the problem that we are trying to solve in this issue.
Room chat avatar is different for user who creates room and for user who has been invited to room
What is the root cause of that problem?
We're using the workspace avatar as the policy room avatar.
But when the user is invited to a policy room, but the user is not a member of that workspace, they don't have access to that information. That's expected because if user is not in the workspace, they shouldn't have access to the policy record.
What changes do you think we should make in order to solve the problem?
We had the same issue before with the workspace name, and fixed it by adding the policyName as a field in the report of the room.
We should do the same here for the workspace avatar, we need to add a policyAvatar field in the report record, which will be synced with the avatar of the workspace, the back-end will also need to be updated to support this.
Then in front-end we'll use that field as a fallback in case the policy avatar is not found. If even that policyAvatar is not available, now we fallback to the default workspace avatar as we currently do.
This way, even though the user doesn't have any access to the workspace data, they can still access the policyAvatar (beside policyName) to display as room avatar.
What alternative solutions did you explore? (Optional)
@getusha - - when you get a chance, can you review if this proposal will fix this issue? Thanks!
Heads up, I will be offline from Friday, December 22, to Thursday, January 4, 2024. I will not be actively watching over this GitHub during that period. If anything urgent is needed here, please ask for help in the #expensify-open-source Slack Room-- thanks!
Activity
[-]Room - Room chat avatar is different for user who creates room & who has been invited to room[/-][+][$500] Room - Room chat avatar is different for user who creates room & who has been invited to room[/+]melvin-bot commentedon Dec 22, 2023
Job added to Upwork: https://www.upwork.com/jobs/~013499a52b4634b0ed
melvin-bot commentedon Dec 22, 2023
Triggered auto assignment to @alexpensify (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.melvin-bot commentedon Dec 22, 2023
Bug0 Triage Checklist (Main S/O)
Platformsin OP are ✅)melvin-bot commentedon Dec 22, 2023
Triggered auto assignment to Contributor-plus team member for initial proposal review - @getusha (
External)unidev727 commentedon Dec 22, 2023
Proposal
from: @unicorndev-727
Please re-state the problem that we are trying to solve in this issue.
Room chat avatar is different for user who creates room & who has been invited to room
What is the root cause of that problem?
The root cause is that the user who has been invited to room doesn't have the policy data about workspace in Onyx so that the default workspace avatar will be showed.
This issue only happens when we invite the user who isn't member of this workspace to the only room.
App/src/libs/ReportUtils.ts
Lines 1247 to 1249 in 8970aa3
It is a screen shot of the room owner.


It is a screen shot of the room invited user.
What changes do you think we should make in order to solve the problem?
We can send the policy update request if
ONYXKEYS.COLLECTION.POLICY}${report?.policyID}is null here.What alternative solutions did you explore? (Optional)
Backend need to send the workspace data to the users who has been invited to the room and isn't the member of the workspace.
dukenv0307 commentedon Dec 22, 2023
Proposal
Please re-state the problem that we are trying to solve in this issue.
Room chat avatar is different for user who creates room and for user who has been invited to room
What is the root cause of that problem?
We're using the workspace avatar as the policy room avatar.
But when the user is invited to a policy room, but the user is not a member of that workspace, they don't have access to that information. That's expected because if user is not in the workspace, they shouldn't have access to the
policyrecord.What changes do you think we should make in order to solve the problem?
We had the same issue before with the workspace name, and fixed it by adding the
policyNameas a field in thereportof the room.We should do the same here for the workspace avatar, we need to add a
policyAvatarfield in thereportrecord, which will be synced with the avatar of the workspace, the back-end will also need to be updated to support this.Then in front-end we'll use that field as a fallback in case the policy avatar is not found. If even that
policyAvataris not available, now we fallback to the default workspace avatar as we currently do.This way, even though the user doesn't have any access to the workspace data, they can still access the
policyAvatar(besidepolicyName) to display as room avatar.What alternative solutions did you explore? (Optional)
NA
alexpensify commentedon Dec 23, 2023
@getusha - - when you get a chance, can you review if this proposal will fix this issue? Thanks!
Heads up, I will be offline from Friday, December 22, to Thursday, January 4, 2024. I will not be actively watching over this GitHub during that period. If anything urgent is needed here, please ask for help in the #expensify-open-source Slack Room-- thanks!
getusha commentedon Dec 25, 2023
@unicorndev-727 do you mind adding more details to the solution you mentioned in your proposal?
136 remaining items
alexpensify commentedon Sep 6, 2024
@techievivek - we need your follow-up here. Thanks!
mvtglobally commentedon Sep 9, 2024
Issue not reproducible during KI retests. (Second week)
techievivek commentedon Sep 9, 2024
QA team just confirmed that this is fixed so we can move forward with the payment here. @alexpensify
alexpensify commentedon Sep 9, 2024
Payouts due: 2024-09-09
Upwork job is here.
alexpensify commentedon Sep 9, 2024
@dukenv0307 - I sent an offer in Upwork. Please accept and I can complete the payment process.
Thanks!
dukenv0307 commentedon Sep 10, 2024
@alexpensify Done, thank you
getusha commentedon Sep 10, 2024
@alexpensify i should get paid on Upwork as well since the issue was created before my ND payment eligibility date.
alexpensify commentedon Sep 10, 2024
@getusha - thanks for flagging, I sent over an offer in Upwork.
alexpensify commentedon Sep 10, 2024
@dukenv0307 - thanks, I completed the payment process in Upwork!
getusha commentedon Sep 11, 2024
@alexpensify accepted the offer. ty!
alexpensify commentedon Sep 11, 2024
Awesome, everyone has been paid via Upwork.
#33470 (comment)