fix(server): incorrect list condition (#13005)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Improved session filtering to use the correct criteria when querying
sessions, ensuring more accurate results based on the action parameter.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
DarkSky
2025-07-03 18:31:11 +08:00
committed by GitHub
parent 7879e12718
commit 41524425bc
3 changed files with 10 additions and 10 deletions

View File

@@ -310,7 +310,7 @@ export class CopilotSessionModel extends BaseModel {
id: getEqCond(sessionId),
deletedAt: null,
pinned: getEqCond(options.pinned),
prompt: getNullCond(fork, ret => ({ action: ret })),
prompt: getNullCond(action, ret => ({ action: ret })),
parentSessionId: getNullCond(fork),
},
];