From e761655df8d6dacfd597c33665a5350893af68de Mon Sep 17 00:00:00 2001 From: Robert Best Date: Sat, 22 Oct 2016 02:32:41 -0400 Subject: [PATCH] Update JIT.js A few logical operators were replaced with their stricter counterpart. --- frontend/src/Metamaps/JIT.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/frontend/src/Metamaps/JIT.js b/frontend/src/Metamaps/JIT.js index 18abca09..409d63f1 100644 --- a/frontend/src/Metamaps/JIT.js +++ b/frontend/src/Metamaps/JIT.js @@ -913,7 +913,7 @@ const JIT = { // this means you want to add a new topic, and then a synapse Create.newTopic.addSynapse = true Create.newTopic.open() - } else if (JIT.tempInit && JIT.tempNode2 != null) { + } else if (JIT.tempInit && JIT.tempNode2 !== null) { // this means you want to create a synapse between two existing topics Create.newTopic.addSynapse = false Create.newSynapse.topic1id = JIT.tempNode.getData('topic').id @@ -1247,7 +1247,7 @@ const JIT = { if (!JIT.nodeWasDoubleClicked()) { var nodeAlreadySelected = node.selected - if( !(e.button===1) ){ + if(e.button!==1){ if (!e.shiftKey) { Control.deselectAllNodes() Control.deselectAllEdges() @@ -1511,7 +1511,7 @@ const JIT = { const self = JIT var synapseText = adj.data.$synapses[0].attributes.desc; //Copy synapse label to clipboard - if(e.button===1 && e.ctrlKey && synapseText != "") clipboard.copy(synapseText); + if(e.button===1 && e.ctrlKey && synapseText !== "") clipboard.copy(synapseText); // catch right click on mac, which is often like ctrl+click if (navigator.platform.indexOf('Mac') !== -1 && e.ctrlKey) {