From 36674f4cf2899c61ebdb367d76ba9b9eef2949b8 Mon Sep 17 00:00:00 2001 From: "G.Ambatte" Date: Thu, 10 Oct 2024 08:48:14 +1300 Subject: [PATCH] Add explicit guard clause to renderHistoryItems --- client/homebrew/editor/snippetbar/snippetbar.jsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/homebrew/editor/snippetbar/snippetbar.jsx b/client/homebrew/editor/snippetbar/snippetbar.jsx index 513b0ab0b..d457d92f2 100644 --- a/client/homebrew/editor/snippetbar/snippetbar.jsx +++ b/client/homebrew/editor/snippetbar/snippetbar.jsx @@ -175,6 +175,8 @@ const Snippetbar = createClass({ }, renderHistoryItems : function() { + if(!this.state.historyExists) return; + return
{_.map(this.state.historyItems, (item, index)=>{ if(item.noData || !item.savedAt) return;