From 803b58c2d41f74b852f6247472d415e1d7103108 Mon Sep 17 00:00:00 2001
From: Harrison Healey <harrisonmhealey@gmail.com>
Date: Thu, 31 Mar 2016 10:33:00 -0400
Subject: Fixed PostsView not unregistering it's PreferenceStore listener when
 unmounting

---
 webapp/components/posts_view.jsx | 1 +
 1 file changed, 1 insertion(+)

(limited to 'webapp/components/posts_view.jsx')

diff --git a/webapp/components/posts_view.jsx b/webapp/components/posts_view.jsx
index 647c7f086..adeef5abc 100644
--- a/webapp/components/posts_view.jsx
+++ b/webapp/components/posts_view.jsx
@@ -385,6 +385,7 @@ export default class PostsView extends React.Component {
     componentWillUnmount() {
         window.removeEventListener('resize', this.handleResize);
         this.scrollStopAction.cancel();
+        PreferenceStore.removeChangeListener(this.updateState);
     }
     componentDidUpdate() {
         if (this.props.postList != null) {
-- 
cgit v1.2.3-1-g7c22

