Skip to content

Commit

Permalink
Merge pull request #22043 from gartung/RecoBTag-PerformanceDB-ESProdu…
Browse files Browse the repository at this point in the history
…cer-update

RecoBTag/PerformanceDB: change ESProducer return type to unique_ptr.
  • Loading branch information
cmsbuild committed Jan 31, 2018
2 parents 0515345 + a3517cf commit 8949f9c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
6 changes: 2 additions & 4 deletions RecoBTag/PerformanceDB/plugins/BtagPerformanceESProducer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ BtagPerformanceESProducer::BtagPerformanceESProducer(const edm::ParameterSet & p

BtagPerformanceESProducer::~BtagPerformanceESProducer() {}

std::shared_ptr<BtagPerformance>
std::unique_ptr<BtagPerformance>
BtagPerformanceESProducer::produce(const BTagPerformanceRecord & iRecord){
ESHandle<PerformancePayload> pl;
//ESHandle<PhysicsPerformancePayload> pl;
Expand All @@ -41,9 +41,7 @@ BtagPerformanceESProducer::produce(const BTagPerformanceRecord & iRecord){



_perf = std::make_shared<BtagPerformance>(*((pl.product())), *((wp.product())));
// _perf = std::make_shared<BtagPerformance>(*((pl.product())), wp);
return _perf;
return std::make_unique<BtagPerformance>(*((pl.product())), *((wp.product())));
}


Expand Down
3 changes: 1 addition & 2 deletions RecoBTag/PerformanceDB/plugins/BtagPerformanceESProducer.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,8 @@ class BtagPerformanceESProducer : public edm::ESProducer{
public:
BtagPerformanceESProducer(const edm::ParameterSet & p);
~BtagPerformanceESProducer() override;
std::shared_ptr<BtagPerformance> produce(const BTagPerformanceRecord &);
std::unique_ptr<BtagPerformance> produce(const BTagPerformanceRecord &);
private:
std::shared_ptr<BtagPerformance> _perf;
edm::ParameterSet pset_;
std::string mypl;
std::string mywp;
Expand Down

0 comments on commit 8949f9c

Please sign in to comment.