From 94672bba98d1f429f1eeed130cfc27711e0a0192 Mon Sep 17 00:00:00 2001 From: Kyle Isom Date: Tue, 24 Oct 2023 13:22:54 -0700 Subject: [PATCH] SimpleConfig: Put was setting key=key, not key=value. --- CMakeLists.txt | 2 +- src/sl/SimpleConfig.cc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7d34897..427d0a0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required(VERSION 3.22) project(scsl LANGUAGES CXX - VERSION 1.1.2 + VERSION 1.1.3 DESCRIPTION "Shimmering Clarity Standard Library") set(CMAKE_CXX_STANDARD 14) diff --git a/src/sl/SimpleConfig.cc b/src/sl/SimpleConfig.cc index e6da017..97453dc 100644 --- a/src/sl/SimpleConfig.cc +++ b/src/sl/SimpleConfig.cc @@ -220,7 +220,7 @@ SimpleConfig::Get(const char *key, std::string defaultValue) void SimpleConfig::Put(std::string &key, const std::string value) { - this->vars[key] = std::move(key); + this->vars[key] = std::move(value); } @@ -228,7 +228,7 @@ void SimpleConfig::Put(const char *key, const std::string value) { auto keyStr = std::string(key); - this->vars[std::move(keyStr)] = std::move(key); + this->vars[std::move(keyStr)] = std::move(value); }