From 0454754762d9389709a5c17a2183b884b38e70df Mon Sep 17 00:00:00 2001 From: Ylva Selling Date: Mon, 4 Mar 2024 14:27:28 +0100 Subject: [PATCH] Move documentation json as it is more efficient Discussed with @alexanderbock --- src/documentation/documentationengine.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/documentation/documentationengine.cpp b/src/documentation/documentationengine.cpp index f65fb810ad..8cb394bf83 100644 --- a/src/documentation/documentationengine.cpp +++ b/src/documentation/documentationengine.cpp @@ -378,10 +378,10 @@ nlohmann::json DocumentationEngine::generateLicenseGroupsJson() const { using K = std::string; using V = nlohmann::json; - for (const std::pair& assetLicense : assetLicenses) { + for (std::pair& assetLicense : assetLicenses) { nlohmann::json entry; entry[NameKey] = assetLicense.first; - entry[AssetKey] = assetLicense.second; + entry[AssetKey] = std::move(assetLicense.second); sortJson(entry[AssetKey], NameKey); assetsJson[LicensesKey].push_back(entry); }