1
1
mirror of https://github.com/mawww/kakoune.git synced 2024-12-11 04:34:27 +03:00

Make set -add replace existing value when applied to a map option

This commit is contained in:
Maxime Coste 2018-03-30 09:26:39 +11:00
parent 436e803e30
commit f6f2dafaf7

View File

@ -142,7 +142,7 @@ bool option_add(HashMap<Key, Value, domain>& opt, StringView str)
HashItem<Key, Value> item;
option_from_string(key_value[0], item.key);
option_from_string(key_value[1], item.value);
opt.insert(std::move(item));
opt[std::move(item.key)] = std::move(item.value);
changed = true;
}
return changed;