skkwan / phase2-l1Calo-analyzer

0 stars 2 forks source link

fix: hasSimilarPt check keeps match once found #12

Closed ekauffma closed 1 year ago

ekauffma commented 1 year ago

The hasSimilarPt test in L1CaloEGammaSingleAnalyzer.cc had an issue where it would reach a gctCluster/L1 eg match as hasSimilarPt=true, then consider an incorrect match, rewriting this to be hasSimilarPt=false. This fix uses an if statement so that hasSimilarPt is not reverted once set to true, and all match candidates in the loop are considered.