Skip to content

Commit cbea12a

Browse files
Update taskLb.cxx
1 parent 8423ae6 commit cbea12a

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

PWGHF/D2H/Tasks/taskLb.cxx

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -255,9 +255,7 @@ struct HfTaskLb {
255255
} // Lambda_c candidates loop for cross checks
256256

257257
for (const auto& candidate : candidates) {
258-
if (!(candidate.hfflag() & 1 << hf_cand_lb::DecayType::LbToLcPi)) { // This should never be true as the loop is over Lb candidates
259-
continue;
260-
}
258+
261259
if (yCandRecoMax >= 0. && std::abs(hfHelper.yLb(candidate)) > yCandRecoMax) {
262260
continue;
263261
}
@@ -304,15 +302,14 @@ struct HfTaskLb {
304302
{
305303
// MC rec
306304
for (const auto& candidate : candidates) {
307-
if (!(candidate.hfflag() & 1 << hf_cand_lb::DecayType::LbToLcPi)) {
308-
continue;
309-
}
305+
310306
if (yCandRecoMax >= 0. && std::abs(hfHelper.yLb(candidate)) > yCandRecoMax) {
311307
continue;
312308
}
313-
auto candLc = candidate.prong0_as<aod::HfCand3Prong>();
309+
auto candLc = candidate.prong0_as<soa::Join<aod::HfCand3Prong, aod::HfCand3ProngMcRec>>();
310+
int flagMcMatchRecLb = std::abs(candidate.flagMcMatchRec());
314311

315-
if (std::abs(candidate.flagMcMatchRec()) == 1 << hf_cand_lb::DecayType::LbToLcPi) {
312+
if (TESTBIT(flagMcMatchRecLb, hf_cand_lb::DecayType::LbToLcPi)) {
316313

317314
auto indexMother = RecoDecay::getMother(mcParticles, candidate.prong1_as<TracksWExtMc>().mcParticle_as<soa::Join<aod::McParticles, aod::HfCandLbMcGen>>(), o2::constants::physics::Pdg::kLambdaB0, true);
318315
auto particleMother = mcParticles.rawIteratorAt(indexMother);

0 commit comments

Comments
 (0)