Skip to content

Commit

Permalink
check newValue for undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
khalidhuseynov committed Dec 29, 2016
1 parent 05b4355 commit d3fface
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@
};

$scope.$watch($scope.getEditor, function(newValue, oldValue) {
if (newValue === null) {
if (newValue === null || newValue === undefined) {
console.log('editor isn\'t loaded yet, returning..');
return;
}
Expand Down

0 comments on commit d3fface

Please sign in to comment.