🚨 front: Fixing a couple of linter warnings

This commit is contained in:
Eric Doughty-Papassideris
2024-11-11 00:52:15 +01:00
committed by ericlinagora
parent 9dc23fdb52
commit e23c897d66
3 changed files with 5 additions and 4 deletions
@@ -8,7 +8,7 @@ import {
useRef,
} from "react";
let interval: any = null;
let interval: ReturnType<typeof setInterval> | null = null;
export const AnimatedHeight = memo(
(props: { children: ReactNode } & InputHTMLAttributes<HTMLDivElement>) => {
@@ -28,7 +28,8 @@ export const AnimatedHeight = memo(
updateSize();
}, 200);
return () => {
clearInterval(interval);
if (interval)
clearInterval(interval);
};
}, []);