From a08d354971c644b8a5152cd93f5eb7c7ab154983 Mon Sep 17 00:00:00 2001 From: Tomas Babej Date: Wed, 2 Sep 2015 22:50:57 +0200 Subject: [PATCH] Urgency: Add backwards compatible handling of next coefficient --- src/Config.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Config.cpp b/src/Config.cpp index 19611c4bc..53dd2f62a 100644 --- a/src/Config.cpp +++ b/src/Config.cpp @@ -661,6 +661,11 @@ const int Config::getInteger (const std::string& key) //////////////////////////////////////////////////////////////////////////////// const double Config::getReal (const std::string& key) { + //NOTE: Backwards compatible handling of next coefficient. + //TODO: Remove. + if (key == "urgency.user.tag.next.coefficient" and has("urgency.next.coefficient")) + return getReal("urgency.next.coefficient"); + if ((*this).find (key) != (*this).end ()) return strtod ((*this)[key].c_str (), NULL);