Bug - import/export now output JSON as individual objects
* For JSON as array, json.array=1 behaves as before * Tests and add-on scripts used in import tests were updated
This commit is contained in:
@@ -71,7 +71,11 @@ int CmdExport::execute (std::string& output)
|
||||
for (task = filtered.begin (); task != filtered.end (); ++task)
|
||||
{
|
||||
if (task != filtered.begin ())
|
||||
output += ",\n";
|
||||
{
|
||||
if (json_array)
|
||||
output += ",";
|
||||
output += "\n";
|
||||
}
|
||||
|
||||
output += task->composeJSON (true);
|
||||
|
||||
|
||||
@@ -76,8 +76,7 @@ int CmdImport::execute (std::string& output)
|
||||
{
|
||||
std::string object = trimLeft (
|
||||
trimRight (
|
||||
trimRight (
|
||||
trim (*line), ","),
|
||||
trim (*line),
|
||||
"]"),
|
||||
"[");
|
||||
// Skip blanks. May be caused by the trim calls above.
|
||||
|
||||
Reference in New Issue
Block a user