🔑 fix: Update Conversation Mutation to use ID from Payload (#8758)

This commit is contained in:
Marco Beretta 2025-07-30 20:34:30 +02:00 committed by GitHub
parent 32081245da
commit 8a1a38f346
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 6 additions and 5 deletions

View file

@ -55,9 +55,10 @@ export const useUpdateConversationMutation = (
return useMutation( return useMutation(
(payload: t.TUpdateConversationRequest) => dataService.updateConversation(payload), (payload: t.TUpdateConversationRequest) => dataService.updateConversation(payload),
{ {
onSuccess: (updatedConvo) => { onSuccess: (updatedConvo, payload) => {
queryClient.setQueryData([QueryKeys.conversation, id], updatedConvo); const targetId = payload.conversationId || id;
updateConvoInAllQueries(queryClient, id, () => updatedConvo); queryClient.setQueryData([QueryKeys.conversation, targetId], updatedConvo);
updateConvoInAllQueries(queryClient, targetId, () => updatedConvo);
}, },
}, },
); );

2
package-lock.json generated
View file

@ -51804,7 +51804,7 @@
}, },
"packages/data-provider": { "packages/data-provider": {
"name": "librechat-data-provider", "name": "librechat-data-provider",
"version": "0.7.902", "version": "0.7.903",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"axios": "^1.8.2", "axios": "^1.8.2",

View file

@ -1,6 +1,6 @@
{ {
"name": "librechat-data-provider", "name": "librechat-data-provider",
"version": "0.7.902", "version": "0.7.903",
"description": "data services for librechat apps", "description": "data services for librechat apps",
"main": "dist/index.js", "main": "dist/index.js",
"module": "dist/index.es.js", "module": "dist/index.es.js",