BUG: Fix crash when clear button press on latest Slicer versions