Skip to content

Commit

Permalink
fix(OrientationMarkerWidget): Use vtkErrorMacro over console.error
Browse files Browse the repository at this point in the history
  • Loading branch information
floryst committed Jan 18, 2018
1 parent 72684c5 commit 4db373b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Sources/Interaction/Widgets/OrientationMarkerWidget/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import macro from 'vtk.js/Sources/macro';
import vtkRenderer from 'vtk.js/Sources/Rendering/Core/Renderer';
import Constants from 'vtk.js/Sources/Interaction/Widgets/OrientationMarkerWidget/Constants';

const { vtkErrorMacro } = macro;

// ----------------------------------------------------------------------------
// vtkOrientationMarkerWidget
// ----------------------------------------------------------------------------
Expand Down Expand Up @@ -59,12 +61,12 @@ function vtkOrientationMarkerWidget(publicAPI, model) {
}

if (!model.actor) {
console.error('Must set actor before enabling orientation marker.');
vtkErrorMacro('Must set actor before enabling orientation marker.');
return;
}

if (!model.interactor) {
console.error(
vtkErrorMacro(
'Must set interactor before enabling orientation marker.'
);
return;
Expand Down

0 comments on commit 4db373b

Please sign in to comment.