invites: redirect multiple member DMs to messages

This commit is contained in:
Matilde Park 2021-02-12 14:30:24 -05:00
parent 73c0c7c2fe
commit 5db4c1307b

View File

@ -61,7 +61,7 @@ export function InviteItem(props: InviteItemProps) {
if (props.groups?.[resource]?.hidden) {
const { metadata } = associations.graph[resource];
if (name.startsWith("dm--")) {
if (metadata?.module === 'chat') {
history.push(`/~landscape/messages/resource/${metadata.module}${resource}`);
} else {
history.push(`/~landscape/home/resource/${metadata.module}${resource}`);
@ -126,7 +126,7 @@ export function InviteItem(props: InviteItemProps) {
<Icon display="block" color="blue" icon="Bullet" mr="2" />
<Text mr="1">You are joining a DM with</Text>
<Text mr="1" mono>
{cite("~hastuc-dibtux")}
{cite(`~${invite!.ship}`)}
</Text>
</Row>
</JoinSkeleton>