Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CIS-1888] Fix DM Channel with multiple members displaying only 1 user avatar #2019

Conversation

nuno-vieira
Copy link
Member

@nuno-vieira nuno-vieira commented May 23, 2022

🔗 Issue Links

CIS-1888

🎯 Goal

Fix issue of DM Channel with multiple members and without channel image assigned showing the image of only one member instead of showing the merged avatar.

🛠 Implementation

Instead of using isDirectMessageChannel to show 1:1 avatar image for the channel, do this only if the memberCount is 2.

🎨 Showcase

The change can be seen in the new snapshot test added 👍

🧪 Manual Testing Notes

  • Open Channel List
  • Create a DM Channel with multiple users
  • Verify that the DM Channel has the avatar merged

☑️ Contributor Checklist

  • I have signed the Stream CLA (required)
  • Changelog is updated with client-facing changes
  • New code is covered by unit tests
  • This change follows zero ⚠️ policy (required)
  • Comparison screenshots added for visual changes
  • Affected documentation updated (docusaurus, tutorial, CMS)

@nuno-vieira nuno-vieira added 🐞 Bug An issue or PR related to a bug 🎨 SDK: StreamChatUI Tasks related to the StreamChatUI SDK labels May 23, 2022
@nuno-vieira nuno-vieira self-assigned this May 23, 2022
@nuno-vieira nuno-vieira requested a review from a team as a code owner May 23, 2022 17:49
@nuno-vieira nuno-vieira force-pushed the fix/CIS-1888-DM-Channel-with-multiple-members-shows-1-user-image branch from 923ccbc to f7854d8 Compare May 23, 2022 17:49
Copy link
Contributor

@evsaev evsaev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚢

@sonarcloud
Copy link

sonarcloud bot commented May 24, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@emerge-tools
Copy link

emerge-tools bot commented May 24, 2022

⬆️ This change increases install size by 22.4 kB ⬆️

Image of diff

🗂 See the Emerge size breakdown
Item Install size
➕ StreamChat.framework/SentryCrashIntegration.enrichScope:crashWrapper: ⬆️ 2.2 kB
➕ StreamChat.framework/SentryUIEventTracker.start ⬆️ 2.1 kB
StreamChat.framework/SentryCrashIntegration.configureScope ⬇️ 1.9 kB
➕ StreamChat.framework/SentryTracer.finishInternal ⬆️ 1.4 kB
StreamChat.framework/Strings.CFStrings ⬆️ 1.2 kB
➕ StreamChat.framework/SentryUIEventTracker.Objc Metadata ⬆️ 1.1 kB
➖ StreamChat.framework/SentryTracer.captureTransaction ⬇️ 1.0 kB
➕ StreamChat.framework/SentryTracer.initWithTransactionContext:hub:waitForChildren:idleTimeout:dispatchQueueWrapper: 848 B
StreamChat.framework/SentryTracer.Objc Metadata 827 B
StreamChat.framework/profiling.enumerateBacktracesForAllThreads 800 B
➕ StreamChat.framework/SentrySdkInfo.initWithDictInternal:orDefaults: 724 B
StreamChat.framework/SentryTracer.initWithTransactionContext:hub:waitForChildren: 708 B
➕ StreamChat.framework/SentryUIEventTrackingIntegration.Objc Metadata 685 B
StreamChat.framework/DYLD.String Table 576 B
StreamChat.framework/SentryProfiler.start 556 B
StreamChat.framework/SentrySdkInfo.initWithDict: 552 B
StreamChat.framework/Code Signature 520 B

🔎 See the full analysis (85143a9) merging into develop (00da858)

Provide a baseSha and pullRequestNumber with your upload to ensure diffs are correct. Read more in the docs

@nuno-vieira nuno-vieira merged commit 1fd4ff3 into develop May 24, 2022
@nuno-vieira nuno-vieira deleted the fix/CIS-1888-DM-Channel-with-multiple-members-shows-1-user-image branch May 24, 2022 12:15
This was referenced Jun 6, 2022
@bielikb bielikb mentioned this pull request Jun 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 Bug An issue or PR related to a bug 🎨 SDK: StreamChatUI Tasks related to the StreamChatUI SDK
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants