Skip to content
This repository was archived by the owner on Sep 11, 2024. It is now read-only.

Commit 35841a6

Browse files
authored
Lint
1 parent 756f72e commit 35841a6

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

src/components/views/settings/tabs/room/BridgeSettingsTab.js

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,15 @@ export default class BridgeSettingsTab extends React.Component {
8080
shouldShowPillAvatar={true}
8181
/> bot user.</p>
8282
);
83+
let channelLink = channelName;
84+
if (channel.external_url) {
85+
channelLink = <a target="_blank" href={channel.external_url}>{channelName}</a>;
86+
}
8387

84-
const channelLink = channel.external_url ? (<a target="_blank" href={channel.external_url}>{channelName}</a>) : channelName;
85-
const networkLink = network && network.external_url ? (<a target="_blank" href={network.external_url}>{networkName}</a>)
86-
: networkName;
88+
let networkLink = networkName;
89+
if (network && network.external_url) {
90+
networkLink = <a target="_blank" href={network.external_url}>{networkName}</a>;
91+
}
8792

8893
const chanAndNetworkInfo = (
8994
<p> Bridged into {channelLink} {networkLink}, on {protocolName}</p>

0 commit comments

Comments
 (0)