285: Pass interval id to extensions

This commit is contained in:
Johannes Hertenstein 2020-02-11 17:55:30 +01:00 committed by lauft
parent e8511c5efd
commit da27fdcdf0

View file

@ -99,16 +99,14 @@ std::string Interval::serialize () const
std::string Interval::json () const
{
std::stringstream out;
out << '{';
out << "{\"id\":" << id;
if (is_started ())
out << "\"start\":\"" << start.toISO () << "\"";
if (is_started ()) {
out << ",\"start\":\"" << start.toISO () << "\"";
}
if (is_ended ())
{
if (is_started ())
out << ',';
out << "\"end\":\"" << end.toISO () << "\"";
if (is_ended ()) {
out << ",\"end\":\"" << end.toISO () << "\"";
}
if (! _tags.empty ())