From 14b9d7784ee832603342f25b5eddb538a8676d74 Mon Sep 17 00:00:00 2001 From: Saturnino Abril Date: Mon, 8 May 2017 21:51:56 +0900 Subject: fix JS error after pinning a post with an empty pinned post list open in RHS (#6345) --- webapp/stores/search_store.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webapp/stores/search_store.jsx b/webapp/stores/search_store.jsx index 2ccf02f94..dd4b97522 100644 --- a/webapp/stores/search_store.jsx +++ b/webapp/stores/search_store.jsx @@ -122,7 +122,7 @@ class SearchStoreClass extends EventEmitter { togglePinPost(postId, isPinned) { const results = this.getSearchResults(); - if (results == null) { + if (results == null || results.posts == null) { return; } -- cgit v1.2.3-1-g7c22