diff --git a/src/commands/CmdInfo.cpp b/src/commands/CmdInfo.cpp index 342e284fa..f35ac9986 100644 --- a/src/commands/CmdInfo.cpp +++ b/src/commands/CmdInfo.cpp @@ -377,7 +377,6 @@ int CmdInfo::execute (std::string& output) // Show any UDAs auto all = task.all (); - std::string type; for (auto& att: all) { if (Context::getContext ().columns.find (att) != Context::getContext ().columns.end ()) @@ -391,9 +390,9 @@ int CmdInfo::execute (std::string& output) row = view.addRow (); view.set (row, 0, col->label ()); - if (type == "date") + if (col->type () == "date") value = Datetime (value).toString (dateformat); - else if (type == "duration") + else if (col->type () == "duration") { Duration iso; std::string::size_type cursor = 0;