mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-07-07 20:06:39 +02:00
trivial:coding-style: Add curly braces around blocks modified recently
timwarrior coding standard is for there to be curly braces around all code blocks. See https://github.com/GothenburgBitFactory/timewarrior/pull/269#discussion_r367937920
This commit is contained in:
parent
f45734efe0
commit
2fcca6f949
13 changed files with 90 additions and 1 deletions
|
@ -44,7 +44,9 @@ int CmdLengthen (
|
|||
std::set <int> ids = cli.getIds ();
|
||||
|
||||
if (ids.empty ())
|
||||
{
|
||||
throw std::string ("IDs must be specified. See 'timew help lengthen'.");
|
||||
}
|
||||
|
||||
std::string delta;
|
||||
|
||||
|
@ -52,7 +54,9 @@ int CmdLengthen (
|
|||
{
|
||||
if (arg.hasTag ("FILTER") &&
|
||||
arg._lextype == Lexer::Type::duration)
|
||||
{
|
||||
delta = arg.attribute ("raw");
|
||||
}
|
||||
}
|
||||
|
||||
journal.startTransaction ();
|
||||
|
@ -64,7 +68,9 @@ int CmdLengthen (
|
|||
for (auto& interval : intervals)
|
||||
{
|
||||
if (interval.is_open ())
|
||||
{
|
||||
throw format ("Cannot lengthen open interval @{1}", interval.id);
|
||||
}
|
||||
|
||||
database.deleteInterval (interval);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue