Skip to content

Commit c4b051f

Browse files
author
Yuanjun Mei
committed
Remove magic number
1 parent bd0a1fa commit c4b051f

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

‎PWGCF/MultiparticleCorrelations/Tasks/multiparticleCorrelationsMei.cxx‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -782,8 +782,9 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to
782782
}
783783
auto mcParticle = track.mcParticle();
784784
auto chargeMC = pdg->GetParticle(mcParticle.pdgCode())->Charge();
785-
if (std::abs(chargeMC) == 3) {
786-
chargeMC /= 3;
785+
const int chargeMCUnit = 3;
786+
if (std::abs(chargeMC) == chargeMCUnit) {
787+
chargeMC /= chargeMCUnit;
787788
}
788789
if constexpr (cuts == eBefore) {
789790
pc.fParticleHistograms[eHistPt][eSim][eBefore]->Fill(mcParticle.pt());

0 commit comments

Comments
 (0)