🌐 feat: Add support to SubDirectory hosting (#9155)

* feat: Add support to SubDirectory hosting

* fix: address linting and failing test

* fix: browser context validation

---------

Co-authored-by: Danny Avila <danny@librechat.ai>
This commit is contained in:
José Pedro Silva 2025-08-27 07:00:18 +01:00 committed by GitHub
parent a820863e8b
commit 18d5a75cdc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
14 changed files with 252 additions and 199 deletions

View file

@ -11,7 +11,7 @@ export default function useAttachmentHandler(queryClient?: QueryClient) {
return ({ data }: { data: TAttachment; submission: EventSubmission }) => {
const { messageId } = data;
if (queryClient && data?.filepath && !data.filepath.startsWith('/api/files')) {
if (queryClient && data?.filepath && !data.filepath.includes('/api/files')) {
queryClient.setQueryData([QueryKeys.files], (oldData: TAttachment[] | undefined) => {
return [data, ...(oldData || [])];
});