mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-08-19 19:03:07 +02:00
CLI
- Made ::entity aware of whether an entity is already known, to avoid adding when not necessary.
This commit is contained in:
parent
d3d3a6a418
commit
6784c8d108
1 changed files with 3 additions and 2 deletions
|
@ -241,9 +241,10 @@ void CLI::alias (const std::string& name, const std::string& value)
|
|||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
void CLI::entity (const std::string& name, const std::string& value)
|
||||
void CLI::entity (const std::string& category, const std::string& name)
|
||||
{
|
||||
_entities.insert (std::pair <std::string, std::string> (name, value));
|
||||
if (_entities.find (category) == _entities.end ())
|
||||
_entities.insert (std::pair <std::string, std::string> (category, name));
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue