From 5ea27dd616b8c6d4e52cf5faad3dac5b001e215a Mon Sep 17 00:00:00 2001 From: Christopher Gurnee Date: Fri, 8 Apr 2022 14:18:57 +0000 Subject: [PATCH] Add componentWillUnmount() to thread/index.js --- src/pages/thread/index.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/pages/thread/index.js b/src/pages/thread/index.js index cb02e50..ab40de4 100644 --- a/src/pages/thread/index.js +++ b/src/pages/thread/index.js @@ -474,6 +474,10 @@ class Thread extends React.Component { }) } + componentWillUnmount () { + this.stopLoading = true + } + render () { const { subreddit, id, author } = this.state.post const { commentID } = this.props.match.params