From 14cd011f4e38fad978d81fac6ea9e7bc7506ddbd Mon Sep 17 00:00:00 2001 From: denz1994 Date: Mon, 9 Mar 2020 15:36:42 -0400 Subject: [PATCH] Remove console.log debugging information at runtime. https://github.com/phetsims/build-a-molecule/issues/115 --- js/common/model/Kit.js | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/js/common/model/Kit.js b/js/common/model/Kit.js index 172e23ab..146ac211 100644 --- a/js/common/model/Kit.js +++ b/js/common/model/Kit.js @@ -528,24 +528,6 @@ class Kit { const newMolecule = MoleculeStructure.getCombinedMoleculeFromBond( molA, molB, a, b, new Molecule() ); - // sanity check and debugging information - if ( !newMolecule.isValid() ) { - // TODO: performance: strip this out for the runtime? - window.console && console.log && console.log( 'invalid molecule!' ); - window.console && console.log && console.log( 'bonding: ' + a.symbol + '(' + a.reference + '), ' + dirAtoB + ' ' + b.symbol + ' (' + b.reference + ')' ); - window.console && console.log && console.log( 'A' ); - window.console && console.log && console.log( molA.getDebuggingDump() ); - window.console && console.log && console.log( 'B' ); - window.console && console.log && console.log( molB.getDebuggingDump() ); - window.console && console.log && console.log( 'combined' ); - window.console && console.log && console.log( newMolecule.getDebuggingDump() ); - - window.console && console.log && console.log( 'found: ' + this.isAllowedStructure( newMolecule ) ); - - // just exit out for now - return; - } - this.removeMolecule( molA ); this.removeMolecule( molB ); this.addMolecule( newMolecule );