mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-08-27 19:17:19 +02:00
Performance
- Added a shortcut test that speeds up the decode process for most cases.
This commit is contained in:
parent
5609711d47
commit
5e4f7feff8
1 changed files with 18 additions and 13 deletions
|
@ -516,6 +516,8 @@ const std::string encode (const std::string& value)
|
|||
// : <- :
|
||||
const std::string decode (const std::string& value)
|
||||
{
|
||||
if (value.find ('&') != std::string::npos)
|
||||
{
|
||||
std::string modified = value;
|
||||
|
||||
// Supported encodings.
|
||||
|
@ -532,6 +534,9 @@ const std::string decode (const std::string& value)
|
|||
str_replace (modified, ":", ":"); // Deprecated 2.0
|
||||
|
||||
return modified;
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue