Skip to content

🍞 fix: don't show 'deleting file' toast on attached files - #13239

Merged
danny-avila merged 1 commit into
LibreChat-AI:devfrom
newjersey:dlew/remove-erroneous-delete-file-warning
May 21, 2026
Merged

danny-avila merged 1 commit into
LibreChat-AI:devfrom
newjersey:dlew/remove-erroneous-delete-file-warning

Conversation

@dlew

@dlew dlew commented May 21, 2026

Copy link
Copy Markdown
Contributor

Summary

There are two ways to add a file to a conversation:

  1. Uploading a new file.
  2. Using an existing file (from the side panel).

If you decide to remove the file, the behavior differs depending on how it was added. If you just uploaded a new file, it gets deleted from the conversation & the system. But if it's an existing file, then it only gets removed from the conversation (but not deleted).

However, in both cases, it would show a toast saying that the file was deleted, which is incorrect for the "existing file" case.

Now we check whether the file is attached (to the system) before showing the deletion toast, and skip showing it if we're not actually deleting the file.

Change Type

  • Bug fix (non-breaking change which fixes an issue)

Testing

I tried deleting files after uploading them & after selecting them from the side panel, to make sure the toast still showed up when deleting new uploads.

Checklist

Please delete any irrelevant options.

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • My changes do not introduce new warnings
  • Local unit tests pass with my changes

There are two ways to add a file to a conversation:

1. Uploading a new file.
2. Using an existing file (from the side panel).

If you decide to remove the file, the behavior differs depending on
how it was added. If you just uploaded a new file, it gets deleted
from the conversation & the system. But if it's an existing file,
then it only gets removed from the conversation (but not deleted).

However, in both cases, it would show a toast saying that the file
was deleted, which is incorrect for the "existing file" case.

Now we check whether the file is `attached` (to the system) before
showing the deletion toast, and skip showing it if we're not actually
deleting the file.
@danny-avila danny-avila changed the title fix: don't show 'deleting file' toast on attached files 🍞 fix: don't show 'deleting file' toast on attached files May 21, 2026
@danny-avila
danny-avila merged commit a865d40 into LibreChat-AI:dev May 21, 2026
9 checks passed
@dlew
dlew deleted the dlew/remove-erroneous-delete-file-warning branch May 21, 2026 20:34
fuuuzzy pushed a commit to fuuuzzy/LibreChat that referenced this pull request May 22, 2026
…AI#13239)

There are two ways to add a file to a conversation:

1. Uploading a new file.
2. Using an existing file (from the side panel).

If you decide to remove the file, the behavior differs depending on
how it was added. If you just uploaded a new file, it gets deleted
from the conversation & the system. But if it's an existing file,
then it only gets removed from the conversation (but not deleted).

However, in both cases, it would show a toast saying that the file
was deleted, which is incorrect for the "existing file" case.

Now we check whether the file is `attached` (to the system) before
showing the deletion toast, and skip showing it if we're not actually
deleting the file.
ThomasVuNguyen pushed a commit to ThomasVuNguyen/LibreChat that referenced this pull request Jul 15, 2026
…AI#13239)

There are two ways to add a file to a conversation:

1. Uploading a new file.
2. Using an existing file (from the side panel).

If you decide to remove the file, the behavior differs depending on
how it was added. If you just uploaded a new file, it gets deleted
from the conversation & the system. But if it's an existing file,
then it only gets removed from the conversation (but not deleted).

However, in both cases, it would show a toast saying that the file
was deleted, which is incorrect for the "existing file" case.

Now we check whether the file is `attached` (to the system) before
showing the deletion toast, and skip showing it if we're not actually
deleting the file.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants