Skip to content

Commit

Permalink
Fix silent error in treenode
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasnordquist committed May 4, 2019
1 parent 6bf8405 commit 3bfc59d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/src/components/Tree/TreeNode.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ class TreeNodeComponent extends React.Component<Props, State> {
}

private viewStateHasChanged = (msg: void) => {
this.setState({ selected: this.props.treeNode.viewModel!.isSelected() })
this.props.treeNode.viewModel && this.setState({ selected: this.props.treeNode.viewModel.isSelected() })
}

private removeSubscriber(treeNode: q.TreeNode<TopicViewModel>) {
Expand Down

0 comments on commit 3bfc59d

Please sign in to comment.