mirror of
https://github.com/Yidadaa/ChatGPT-Next-Web.git
synced 2025-08-08 06:57:33 +08:00
feat: add upstash redis cloud sync
This commit is contained in:
@@ -69,6 +69,9 @@ const MergeStates: StateMerger = {
|
||||
localState.sessions.forEach((s) => (localSessions[s.id] = s));
|
||||
|
||||
remoteState.sessions.forEach((remoteSession) => {
|
||||
// skip empty chats
|
||||
if (remoteSession.messages.length === 0) return;
|
||||
|
||||
const localSession = localSessions[remoteSession.id];
|
||||
if (!localSession) {
|
||||
// if remote session is new, just merge it
|
||||
|
Reference in New Issue
Block a user