Task: Improved method signature

This commit is contained in:
Paul Beckingham 2016-12-31 15:55:06 -05:00
parent fab2979b87
commit 7e629ef30a
10 changed files with 21 additions and 49 deletions

View file

@ -142,9 +142,7 @@ int CmdTimesheet::execute (std::string& output)
std::string description = task.get ("description");
int indent = context.config.getInteger ("indent.annotation");
std::map <std::string, std::string> annotations;
task.getAnnotations (annotations);
for (auto& ann : annotations)
for (auto& ann : task.getAnnotations ())
description += '\n'
+ std::string (indent, ' ')
+ Datetime (ann.first.substr (11)).toString (context.config.get ("dateformat"))
@ -198,9 +196,7 @@ int CmdTimesheet::execute (std::string& output)
std::string description = task.get ("description");
int indent = context.config.getInteger ("indent.annotation");
std::map <std::string, std::string> annotations;
task.getAnnotations (annotations);
for (auto& ann : annotations)
for (auto& ann : task.getAnnotations ())
description += '\n'
+ std::string (indent, ' ')
+ Datetime (ann.first.substr (11)).toString (context.config.get ("dateformat"))