commit 4b3d4eaeb0b466543862a3e9b08e83d51a5ba555
parent 4b2a2d1205dd51b0ae0fb73d23dc0331562d308a
Author: cfillion <cfillion@users.noreply.github.com>
Date: Sun, 3 May 2020 00:22:47 -0400
remove bad return value of ActionList::add
action.get() is no longer valid as the unique_ptr was moved
Diffstat:
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/src/action.hpp b/src/action.hpp
@@ -43,12 +43,10 @@ private:
class ActionList {
public:
- template<typename... Args> Action *add(Args&&... args)
+ template<typename... Args> void add(Args&&... args)
{
auto action = std::make_unique<Action>(args...);
m_list.emplace(action->id(), std::move(action));
-
- return action.get();
}
bool run(Action::CommandID id) const;