Code Cleanup
- No blank line when printing information about project changes.
This commit is contained in:
committed by
Paul Beckingham
parent
b1e63e575a
commit
2b20009b7f
@@ -449,8 +449,7 @@ std::string onProjectChange (Task& task, bool scope /* = true */)
|
|||||||
|
|
||||||
msg << format (STRING_HELPER_PROJECT_COMPL, project, percentage)
|
msg << format (STRING_HELPER_PROJECT_COMPL, project, percentage)
|
||||||
<< " "
|
<< " "
|
||||||
<< format (STRING_HELPER_PROJECT_REM, count_pending, count_pending + count_done)
|
<< format (STRING_HELPER_PROJECT_REM, count_pending, count_pending + count_done);
|
||||||
<< "\n";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return msg.str ();
|
return msg.str ();
|
||||||
@@ -462,10 +461,13 @@ std::string onProjectChange (Task& task1, Task& task2)
|
|||||||
if (task1.get ("project") == task2.get ("project"))
|
if (task1.get ("project") == task2.get ("project"))
|
||||||
return onProjectChange (task1);
|
return onProjectChange (task1);
|
||||||
|
|
||||||
std::string messages = onProjectChange (task1);
|
std::string messages1 = onProjectChange (task1);
|
||||||
messages += onProjectChange (task2);
|
std::string messages2 = onProjectChange (task2);
|
||||||
|
|
||||||
return messages;
|
if (messages1.length () && messages2.length ())
|
||||||
|
return messages1 + '\n' + messages2;
|
||||||
|
|
||||||
|
return messages1 + messages2;
|
||||||
}
|
}
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
@@ -474,8 +476,7 @@ std::string onExpiration (Task& task)
|
|||||||
std::stringstream msg;
|
std::stringstream msg;
|
||||||
|
|
||||||
if (context.verbose ("affected"))
|
if (context.verbose ("affected"))
|
||||||
msg << format (STRING_FEEDBACK_EXPIRED, task.id, task.get ("description"))
|
msg << format (STRING_FEEDBACK_EXPIRED, task.id, task.get ("description"));
|
||||||
<< "\n";
|
|
||||||
|
|
||||||
return msg.str ();
|
return msg.str ();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user