diff --git a/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp b/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp index 86ab8c0954c973deb343aa8997ff5442408796df..f1e1564aad212c82ee19e51a992369270d70507f 100644 --- a/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp +++ b/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp @@ -15,8 +15,6 @@ #include "MantidKernel/System.h" #include "MantidMDAlgorithms/IntegratePeaksMD.h" -using Mantid::DataObjects::PeaksWorkspace; - namespace Mantid { namespace MDAlgorithms { @@ -85,7 +83,7 @@ void CentroidPeaksMD2::integrate(typename MDEventWorkspace<MDE, nd>::sptr ws) { // Get a direct ref to that peak. IPeak &p = peakWS->getPeak(i); Peak *peak = dynamic_cast<Peak *>(&p); - double detectorDistance; + double detectorDistance = 0.; if (peak) detectorDistance = p.getL2();