Skip to content

fix: external drag and drop more then one file into the filemanager#191

Open
cehter wants to merge 23 commits into
n1crack:masterfrom
cehter:master
Open

fix: external drag and drop more then one file into the filemanager#191
cehter wants to merge 23 commits into
n1crack:masterfrom
cehter:master

Conversation

@cehter

@cehter cehter commented Jul 7, 2026

Copy link
Copy Markdown

Summary

  • The error occurred directly in the file manager, not in the upload dialogue.
  • External drag-and-drop of more than one file did not work. Only the first file in the array was added.

Fix

Claude Code made me aware of the fact that the webkitGetAsEntry()/getAsFile() calls are not working after the first await. The data has to be collected before the asynchronous scanFiles call.

const entries = fileItems.map((item) => ({
  entry: (item as any).webkitGetAsEntry?.(),
  file: item.getAsFile(),
}));

Tests

  • vitest: Test files - 2 passed, Tests - 20 passed

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.

1 participant