From 9686bab8ec3008623c1f8827df8d831a70ce5e6b Mon Sep 17 00:00:00 2001 From: crupest Date: Tue, 12 Jan 2021 22:10:47 +0800 Subject: ... --- FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'FrontEnd/src') diff --git a/FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx b/FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx index 5c87756c..5833c541 100644 --- a/FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx +++ b/FrontEnd/src/app/views/timeline-common/TimelinePageTemplate.tsx @@ -132,13 +132,9 @@ export default function TimelinePageTemplate( } })(); - const closeDialog = React.useCallback((): void => { - setDialog(null); - }, []); - - let dialogElement: React.ReactElement | undefined; - const timeline = timelineAndStatus?.data; + let dialogElement: React.ReactElement | undefined; + const closeDialog = (): void => setDialog(null); if (dialog === "property") { if (timeline == null || timeline === "notexist") { -- cgit v1.2.3