Skip to content

Commit

Permalink
Merge 6197ee2 into 3d48458
Browse files Browse the repository at this point in the history
  • Loading branch information
BarbourSmith committed Sep 2, 2019
2 parents 3d48458 + 6197ee2 commit 386de26
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/js/molecules/molecule.js
Original file line number Diff line number Diff line change
Expand Up @@ -222,9 +222,11 @@ export default class Molecule extends Atom{

//removes 3d view menu on background click
let viewerBar = document.querySelector('#viewer_bar')
while (viewerBar.firstChild) {
viewerBar.removeChild(viewerBar.firstChild)
viewerBar.setAttribute('style', 'background-color:none;')
if(viewerBar && viewerBar.firstChild){
while (viewerBar.firstChild) {
viewerBar.removeChild(viewerBar.firstChild)
viewerBar.setAttribute('style', 'background-color:none;')
}
}

if(this.uniqueID != GlobalVariables.currentMolecule.uniqueID || GlobalVariables.runMode){ //If you single click to select a molecule OR if we are in run mode
Expand Down

0 comments on commit 386de26

Please sign in to comment.