From ccfb0d78ae71da80c065a7d8071e5aa37d575161 Mon Sep 17 00:00:00 2001 From: Florent Rougon Date: Thu, 21 Dec 2017 08:14:18 +0100 Subject: [PATCH] Add-ons: whitespace-strip every leaf node contents in addon-metadata.xml files All nodes were already stripped except , and ; these are the ones affected by this change. --- src/Add-ons/Addon.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Add-ons/Addon.cxx b/src/Add-ons/Addon.cxx index 7aef87e91..dc9b96f69 100644 --- a/src/Add-ons/Addon.cxx +++ b/src/Add-ons/Addon.cxx @@ -370,7 +370,7 @@ Addon Addon::fromAddonDir(const SGPath& addonPath) "no /addon/version node found in add-on metadata file '" + metadataFile.utf8Str() + "'"); } - AddonVersion addonVersion(versionNode->getStringValue()); + AddonVersion addonVersion(strutils::strip(versionNode->getStringValue())); string addonAuthors; SGPropertyNode *authorsNode = addonNode->getChild("authors"); @@ -413,13 +413,13 @@ Addon Addon::fromAddonDir(const SGPath& addonPath) string addonMinFGVersionRequired; SGPropertyNode *minNode = addonNode->getChild("min-FG-version"); if (minNode != nullptr) { - addonMinFGVersionRequired = minNode->getStringValue(); + addonMinFGVersionRequired = strutils::strip(minNode->getStringValue()); } string addonMaxFGVersionRequired; SGPropertyNode *maxNode = addonNode->getChild("max-FG-version"); if (maxNode != nullptr) { - addonMaxFGVersionRequired = maxNode->getStringValue(); + addonMaxFGVersionRequired = strutils::strip(maxNode->getStringValue()); } string addonHomePage, addonDownloadUrl, addonSupportUrl, addonCodeRepoUrl;