Added braces to avoid a compiler warning.
This commit is contained in:
parent
177b5adc98
commit
3db0accc68
1 changed files with 4 additions and 2 deletions
|
|
@ -126,10 +126,12 @@ void time_log_t::clock_in(const datetime_t& checkin,
|
||||||
{
|
{
|
||||||
time_entry_t event(checkin, account, desc);
|
time_entry_t event(checkin, account, desc);
|
||||||
|
|
||||||
if (! time_entries.empty())
|
if (! time_entries.empty()) {
|
||||||
foreach (time_entry_t& time_entry, time_entries)
|
foreach (time_entry_t& time_entry, time_entries) {
|
||||||
if (event.account == time_entry.account)
|
if (event.account == time_entry.account)
|
||||||
throw parse_error("Cannot double check-in to the same account");
|
throw parse_error("Cannot double check-in to the same account");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
time_entries.push_back(event);
|
time_entries.push_back(event);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue