mirror of
https://github.com/ikechan8370/chatgpt-plugin.git
synced 2025-12-16 05:17:10 +00:00
fix: history manager
This commit is contained in:
parent
1788ee6d7d
commit
0c602d6cb3
2 changed files with 3 additions and 1 deletions
|
|
@ -30,6 +30,7 @@ import { SQLiteProcessorsStorage } from './storage/sqlite/processors_storage.js'
|
|||
import { SQLiteUserStateStorage } from './storage/sqlite/user_state_storage.js'
|
||||
import { SQLiteToolsGroupStorage } from './storage/sqlite/tool_groups_storage.js'
|
||||
import { checkMigrate } from './storage/sqlite/migrate.js'
|
||||
import { SQLiteHistoryManager } from './storage/sqlite/history_manager.js'
|
||||
|
||||
/**
|
||||
* 认证,以便共享上传
|
||||
|
|
@ -144,6 +145,7 @@ export async function initChaite () {
|
|||
await userStateStorage.initialize()
|
||||
toolsGroupStorage = new SQLiteToolsGroupStorage(dbPath)
|
||||
await toolsGroupStorage.initialize()
|
||||
historyStorage = new SQLiteHistoryManager(dbPath, path.join(dataDir, 'images'))
|
||||
await checkMigrate()
|
||||
break
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ export class YunzaiUserState {
|
|||
this.settings = {}
|
||||
this.current = {
|
||||
conversationId,
|
||||
messageId: ''
|
||||
messageId: crypto.randomUUID()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue