mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
MM-56759 Fix crash caused by joinPrivateChannelPrompt (#26123)
When an admin clicks on a link to a private channel they're not a member of, this crashed the app by incorrectly trying to render a Channel object instead of its name
This commit is contained in:
parent
2e40ede7dd
commit
f92d08e991
@ -1397,7 +1397,7 @@ export async function handleFormattedTextClick(e: React.MouseEvent, currentRelat
|
||||
}
|
||||
}
|
||||
if (!member) {
|
||||
const {data} = await store.dispatch(joinPrivateChannelPrompt(team, channel, false));
|
||||
const {data} = await store.dispatch(joinPrivateChannelPrompt(team, channel.display_name, false));
|
||||
if (data.join) {
|
||||
let error = false;
|
||||
if (!getTeamMemberships(state)[team.id]) {
|
||||
|
Loading…
Reference in New Issue
Block a user