diff --git a/include/picongpu/fields/incidentField/profiles/GaussianPulse.def b/include/picongpu/fields/incidentField/profiles/GaussianPulse.def index 56db1a698f..ceb983ce58 100644 --- a/include/picongpu/fields/incidentField/profiles/GaussianPulse.def +++ b/include/picongpu/fields/incidentField/profiles/GaussianPulse.def @@ -85,10 +85,10 @@ namespace picongpu::fields::incidentField::profiles nlohmann::json laguerreModesJson = nlohmann::json::array(); nlohmann::json laguerrePhasesJson = nlohmann::json::array(); - for(uint32_t i = 0; i <= MODENUMBER; ++i) + for(uint32_t i = 0; i <= numModes; ++i) { - laguerreModesJson.push_back(LAGUERREMODES_t{}[i]); - laguerrePhasesJson.push_back(LAGUERREPHASES_t{}[i]); + laguerreModesJson.push_back(laguerreModes[i]); + laguerrePhasesJson.push_back(laguerrePhases[i]); } gaussianMetadata["Laguerre modes"] = {{"value", laguerreModesJson}, {"unit", "none"}};