From 93fb4f9e79ce16fa539137dcaa54f449022e7db9 Mon Sep 17 00:00:00 2001 From: Renard Date: Sat, 28 Sep 2019 16:33:20 -0300 Subject: Fix: remove eventListener on unmount --- src/Home.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Home.js b/src/Home.js index 6b2e385..0cdad72 100644 --- a/src/Home.js +++ b/src/Home.js @@ -73,6 +73,7 @@ class Home extends Component { componentWillUnmount() { clearInterval(this.state.autoRefresh); + window.removeEventListener("mousemove", this.handeMouseMove); } async updateAges() { -- cgit v1.2.1-18-gbd029