mirror of
https://github.com/shumaiOne/shumai.git
synced 2026-12-02 22:14:50 +00:00
fix(agent): prevent userComment entry duplication by passing userCommentId as active prompt entry ID
This commit is contained in:
@@ -135,6 +135,9 @@ export async function createAgentSession(params: CreateAgentSessionParams) {
|
||||
sessionId,
|
||||
cwd: process.cwd(),
|
||||
})
|
||||
if (passedUserCommentId) {
|
||||
storage.nextEntryId = passedUserCommentId
|
||||
}
|
||||
const session = new Session(storage)
|
||||
|
||||
const agentDir = path.join(process.cwd(), '.pi', 'agents', agentId)
|
||||
|
||||
Reference in New Issue
Block a user