From ee1f6c772e164d24e0896c88be200f75d8e371aa Mon Sep 17 00:00:00 2001 From: David Baker Date: Thu, 19 Jan 2017 16:50:09 +0000 Subject: [PATCH] Remove duplicate case handled above And fix typo where it was handled --- src/components/views/dialogs/ChatInviteDialog.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/components/views/dialogs/ChatInviteDialog.js b/src/components/views/dialogs/ChatInviteDialog.js index c117944482..5cbb0d4503 100644 --- a/src/components/views/dialogs/ChatInviteDialog.js +++ b/src/components/views/dialogs/ChatInviteDialog.js @@ -124,7 +124,7 @@ module.exports = React.createClass({ e.stopPropagation(); e.preventDefault(); this.addressSelector.moveSelectionDown(); - } else if (this.state.queryList.length > 0 && (e.keyCode === 188, e.keyCode === 13 || e.keyCode === 9)) { // comma or enter or tab + } else if (this.state.queryList.length > 0 && (e.keyCode === 188 || e.keyCode === 13 || e.keyCode === 9)) { // comma or enter or tab e.stopPropagation(); e.preventDefault(); this.addressSelector.chooseSelection(); @@ -138,8 +138,6 @@ module.exports = React.createClass({ if (this.refs.textinput.value == '') { // if there's nothing in the input box, submit the form this.onButtonClick(); - } else if (this.state.queryList.length > 0) { - this.addressSelector.chooseSelection(); } else { const addrType = Invite.getAddressType(this.refs.textinput.value); if (addrType !== null) {