Page MenuHomePhabricator

D13745.id45324.diff
No OneTemporary

D13745.id45324.diff

diff --git a/web/avatars/thread-avatar.react.js b/web/avatars/thread-avatar.react.js
--- a/web/avatars/thread-avatar.react.js
+++ b/web/avatars/thread-avatar.react.js
@@ -4,8 +4,9 @@
import { useAvatarForThread } from 'lib/hooks/avatar-hooks.js';
import { useResolvedThreadAvatar } from 'lib/shared/avatar-utils.js';
-import { getSingleOtherUser } from 'lib/shared/thread-utils.js';
+import { getSingleOtherUser, getCommunity } from 'lib/shared/thread-utils.js';
import type { AvatarSize } from 'lib/types/avatar-types.js';
+import type { CommunityInfo } from 'lib/types/community-types.js';
import type {
ThreadInfo,
RawThreadInfo,
@@ -33,6 +34,14 @@
state => state.currentUserInfo && state.currentUserInfo.id,
);
+ const communityID = getCommunity(threadInfo);
+ const communityInfo: ?CommunityInfo = useSelector(state => {
+ if (!communityID) {
+ return null;
+ }
+ return state.communityStore.communityInfos[communityID];
+ });
+
let displayUserIDForThread;
if (threadTypeIsPrivate(threadInfo.type)) {
displayUserIDForThread = viewerID;
@@ -57,7 +66,7 @@
const resolvedThreadAvatar = useResolvedThreadAvatar(avatarInfo, {
userProfileInfo: displayUser,
- channelInfo: { fcChannelID: null },
+ channelInfo: { fcChannelID: communityInfo?.farcasterChannelID },
});
return (

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 23, 1:16 AM (17 h, 59 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2567009
Default Alt Text
D13745.id45324.diff (1 KB)

Event Timeline