Task: Prevent double json-decoding of attribute values

In bd4a7081, json-decoding of attribute values was introduced as a
workaround to properly handle blackslashes in description and
annotations (see TW-880).

However, this behaviour is no longer present with the new parser and
introduces its own suite of issues (i.e. see #2140).

Closes #2140.
This commit is contained in:
Tomas Babej 2020-12-31 14:23:51 -05:00
parent 942f43d195
commit 1a001caedd
No known key found for this signature in database
GPG key ID: B0747C6578F7D2F5

View file

@ -269,7 +269,7 @@ time_t Task::get_date (const std::string& name) const
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
void Task::set (const std::string& name, const std::string& value) void Task::set (const std::string& name, const std::string& value)
{ {
data[name] = json::decode (value); data[name] = value;
if (! name.compare (0, 11, "annotation_", 11)) if (! name.compare (0, 11, "annotation_", 11))
++annotation_count; ++annotation_count;