Browse Source

fix(channels): fix invalid assignment error that was not allowing channel details to toggle open on click in production builds

renovate/lint-staged-8.x
Jack Mallers 7 years ago
parent
commit
da4ae24675
  1. 6
      app/components/Contacts/Network.js

6
app/components/Contacts/Network.js

@ -82,12 +82,12 @@ class Network extends Component {
} }
// when a user clicks a channel // when a user clicks a channel
const channelClicked = channel => { const channelClicked = clickedChannel => {
// selectedChannel === channel ? setSelectedChannel(null) : setSelectedChannel(channel) // selectedChannel === channel ? setSelectedChannel(null) : setSelectedChannel(channel)
if (selectedChannel === channel) { if (selectedChannel === clickedChannel) {
setSelectedChannel(null) setSelectedChannel(null)
} else { } else {
setSelectedChannel(channel) setSelectedChannel(clickedChannel)
} }
} }

Loading…
Cancel
Save