diff --git a/src/components/Lesson/LocalFilter/index.tsx b/src/components/Lesson/LocalFilter/index.tsx index 544a5f1..c691735 100644 --- a/src/components/Lesson/LocalFilter/index.tsx +++ b/src/components/Lesson/LocalFilter/index.tsx @@ -36,7 +36,9 @@ export default function LocalFilter({ document.body.style.overflow = ''; } - onToggleOpen && onToggleOpen(isOpen); + if (onToggleOpen) { + onToggleOpen(isOpen); + } return () => { document.body.style.overflow = '';