From f52e8f76c6157600a2d485e37e8e9028769f5841 Mon Sep 17 00:00:00 2001 From: Evil Eye Date: Wed, 29 Nov 2023 16:59:01 +0100 Subject: [PATCH] Use std::erase instead of using std::remove without erasing --- components/lua_ui/element.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/lua_ui/element.cpp b/components/lua_ui/element.cpp index 71f2ba9c96..baa3438982 100644 --- a/components/lua_ui/element.cpp +++ b/components/lua_ui/element.cpp @@ -99,7 +99,7 @@ namespace LuaUi if (parent) { auto children = parent->children(); - std::remove(children.begin(), children.end(), root); + std::erase(children, root); parent->setChildren(children); root->widget()->detachFromWidget(); }