From 5c1a5c6d15dca9eab2fdaaa2e5f831e9caa94cae Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Tue, 20 Mar 2018 20:11:15 +1100 Subject: [PATCH] Revert "Throw when trying to remove a child highlighter that does not exists" This reverts commit 56237aa8f8adaffc63584a6e8435b9cf414d82ef. Throwing seems more correct, but it breaks lots of existing scripts. reverting for now until we have a nice solution. --- src/highlighter_group.cc | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/highlighter_group.cc b/src/highlighter_group.cc index 01a62e9c..1b3ba415 100644 --- a/src/highlighter_group.cc +++ b/src/highlighter_group.cc @@ -39,8 +39,6 @@ void HighlighterGroup::add_child(HighlighterAndId&& hl) void HighlighterGroup::remove_child(StringView id) { - if (not m_highlighters.contains(id)) - throw runtime_error{format("no such child: {}", id)}; m_highlighters.remove(id); }