File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 760760 }
761761
762762 function persistHistory (entries ) {
763- if (typeof window === ' undefined' || typeof window .localStorage === ' undefined' ) return ;
763+ if (typeof window === ' undefined' || typeof window .localStorage === ' undefined' || historyEnabled === false ) return ;
764764 try {
765765 window .localStorage .setItem (HISTORY_STORAGE_KEY , JSON .stringify (entries));
766766 } catch (error) {
975975 }
976976
977977 function addConversationToHistory (sessionUuid , prompt , data ) {
978- if (typeof window === ' undefined' || ! sessionUuid) return null ;
978+ if (typeof window === ' undefined' || ! sessionUuid || historyEnabled === false ) return null ;
979979
980980 const entries = loadStoredHistory ();
981981 const existingIndex = entries .findIndex (item => item .uuid === sessionUuid);
13301330 __refreshDarkMode ();
13311331
13321332 if (data .status === ' finished' ) {
1333- if (currentSessionUuid) {
1333+ if (currentSessionUuid && historyEnabled !== false ) {
13341334 const savedEntry = addConversationToHistory (currentSessionUuid, lastSubmittedPrompt, data);
13351335 if (savedEntry) {
13361336 activeHistoryId = savedEntry .id ;
You can’t perform that action at this time.
0 commit comments