Skip to content

Commit

Permalink
#672 dispalyed diagram only when container existed
Browse files Browse the repository at this point in the history
  • Loading branch information
limouri committed Sep 28, 2016
1 parent ab910bb commit 6398ef2
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ angular.module('metadatamanagementApp').directive('diagram',
var drawDiagram = function() {
$timeout(function() {
scope.isNotLoaded = false;
Plotly.newPlot('diagram', data);
if (angular.element('diagram').length > 0) {
Plotly.newPlot('diagram', data);
}
}, 1000);
};
function createString(object) {
Expand Down

0 comments on commit 6398ef2

Please sign in to comment.