Use FlairStore's cache for group naming

Turns out GroupStore doesn't really know much.
This commit is contained in:
Travis Ralston 2020-08-28 14:56:59 -06:00
parent e68c4efd0b
commit 90d9d7128d
5 changed files with 34 additions and 10 deletions

View file

@ -76,8 +76,8 @@ export function showCommunityInviteDialog(communityId) {
});
if (!chat) chat = rooms[0];
if (chat) {
const summary = GroupStore.getSummary(communityId);
showCommunityRoomInviteDialog(chat.roomId, summary?.profile?.name || communityId);
const name = CommunityPrototypeInviteDialog.instance.getCommunityName(communityId);
showCommunityRoomInviteDialog(chat.roomId, name);
} else {
throw new Error("Failed to locate appropriate room to start an invite in");
}