diff --git a/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp b/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp index 1d4b883d..52e49002 100644 --- a/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp +++ b/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp @@ -320,7 +320,7 @@ StatusCode EDM4hep2LcioTool::convertCollections(lcio::LCEventImpl* lcio_event) { // Start off with the pre-defined collection name mappings auto collsToConvert{m_collNames.value()}; // We *always* want to convert the EventHeader - collsToConvert.emplace("EventHeader", "EventHeader"); + collsToConvert.emplace(edm4hep::EventHeaderName, ""); if (m_convertAll) { info() << "Converting all collections from EDM4hep to LCIO" << endmsg; // And simply add the rest, exploiting the fact that emplace will not diff --git a/k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp b/k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp index e5cadfdf..d0f7222e 100644 --- a/k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp +++ b/k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp @@ -143,8 +143,8 @@ namespace { StatusCode Lcio2EDM4hepTool::convertCollections(lcio::LCEventImpl* the_event) { // Convert Event Header outside the collections loop - if (!collectionExist("EventHeader")) { - registerCollection("EventHeader", LCIO2EDM4hepConv::createEventHeader(the_event)); + if (!collectionExist(edm4hep::EventHeaderName)) { + registerCollection(edm4hep::EventHeaderName, LCIO2EDM4hepConv::createEventHeader(the_event)); } // Start off with the pre-defined collection name mappings