Skip to content

Commit

Permalink
Removed unneeded range checking. (cms-patatrack#614)
Browse files Browse the repository at this point in the history
  • Loading branch information
ericcano committed Apr 16, 2021
1 parent e61008c commit 661b456
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions RecoPixelVertexing/PixelTrackFitting/plugins/storeTracks.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ void storeTracks(Ev& ev, const TWH& tracksWithHits, const TrackerTopology& ttopo
reco::TrackExtra theTrackExtra{};

//fill the TrackExtra with TrackingRecHitRef
unsigned int nHits = tracks->at(k).numberOfValidHits();
unsigned int nHits = (*tracks)[k].numberOfValidHits();
theTrackExtra.setHits(hitCollProd, cc, nHits);
cc += nHits;
AlgebraicVector5 v = AlgebraicVector5(0, 0, 0, 0, 0);
Expand All @@ -63,7 +63,7 @@ void storeTracks(Ev& ev, const TWH& tracksWithHits, const TrackerTopology& ttopo

for (int k = 0; k < nTracks; k++) {
const reco::TrackExtraRef theTrackExtraRef(ohTE, k);
(tracks->at(k)).setExtra(theTrackExtraRef);
(*tracks)[k].setExtra(theTrackExtraRef);
}

ev.put(std::move(tracks));
Expand Down

0 comments on commit 661b456

Please sign in to comment.