diff --git a/src/policy_cache.hpp b/src/policy_cache.hpp index 51ab3dfc..185e110a 100644 --- a/src/policy_cache.hpp +++ b/src/policy_cache.hpp @@ -49,9 +49,13 @@ public: nonstd::optional find(std::string const key_) { - std::string rv; + nonstd::optional rv; - _cache.visit(key_,[](Map::value_type &v){}); + _cache.visit(key_, + [](Map::value_type &v_) + { + rv = v_; + }); return rv; }