From 80052949d95d3808b18f1f018b21a88540bbbc98 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Wed, 17 Jun 2015 01:41:35 -0700 Subject: [PATCH] CmdUndo: Converted from CLI to CLI2 --- src/commands/CmdUndo.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/commands/CmdUndo.cpp b/src/commands/CmdUndo.cpp index a5ed130f4..908d06bd0 100644 --- a/src/commands/CmdUndo.cpp +++ b/src/commands/CmdUndo.cpp @@ -45,9 +45,8 @@ CmdUndo::CmdUndo () int CmdUndo::execute (std::string& output) { // Detect attempts to modify the task. - for (auto& a : context.cli._args) - if (a.hasTag ("MODIFICATION")) - throw std::string (STRING_CMD_UNDO_MODS); + if (context.cli2.getWords ().size ()) + throw std::string (STRING_CMD_UNDO_MODS); context.tdb2.revert (); return 0;