Fixes bug that was causing the edges to disappear when a node was selected.