diff --git a/GUI/coregui/utils/ImportDataInfo.cpp b/GUI/coregui/utils/ImportDataInfo.cpp index d78fd812efab8ef66a3f56698d78bc49c88af04f..11e0f748dd529df76e739a6669dd368144814bcf 100644 --- a/GUI/coregui/utils/ImportDataInfo.cpp +++ b/GUI/coregui/utils/ImportDataInfo.cpp @@ -99,9 +99,7 @@ QString ImportDataInfo::axisLabel(size_t axis_index) const else if (rank == 1) { if (axis_index > 0) return "Signal [a.u.]"; - - auto label_map = AxisNames::specAxis; - return QString::fromStdString(label_map[m_units]); + return QString::fromStdString(AxisNames::specAxis.at(m_units)); } throw GUIHelpers::Error("Error in ImportDataInfo::axisLabel: unsupported data type"); }