Guard for null reference

This commit is contained in:
John Lewin 2017-07-13 15:35:05 -07:00
parent 21fe181589
commit 1e1cf68070

View file

@ -115,7 +115,7 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
viewControls3D.ResetView += (sender, e) =>
{
if (gcode2DWidget.Visible)
if (gcode2DWidget?.Visible == true)
{
gcode2DWidget.CenterPartInView();
}