From b4f1cb259e16e3b11cc6ed4b2f917016b69ba6cc Mon Sep 17 00:00:00 2001 From: emb <> Date: Mon, 3 Aug 2015 21:39:42 -0500 Subject: [PATCH] Fix variables not being set in config when no collection was being passed --- RetroFE/Source/Database/Configuration.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/RetroFE/Source/Database/Configuration.cpp b/RetroFE/Source/Database/Configuration.cpp index 73c29fb..f385235 100644 --- a/RetroFE/Source/Database/Configuration.cpp +++ b/RetroFE/Source/Database/Configuration.cpp @@ -130,11 +130,12 @@ bool Configuration::parseLine(std::string collection, std::string keyPrefix, std key = trimEnds(key); + value = line.substr(position + delimiter.length(), line.length()); + value = trimEnds(value); + // only overwrite the collection name if we know it. We could be parsing a launcher configuration if(collection != "") { - value = line.substr(position + delimiter.length(), line.length()); - value = trimEnds(value); value = Utils::replace(value, "%ITEM_COLLECTION_NAME%", collection); }