Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix console drag-and-drop uploads #1946

Merged
merged 1 commit into from
Mar 6, 2025
Merged

Fix console drag-and-drop uploads #1946

merged 1 commit into from
Mar 6, 2025

Conversation

joshk
Copy link
Collaborator

@joshk joshk commented Mar 6, 2025

No description provided.

@joshk joshk requested a review from nshoes March 6, 2025 00:09
@nshoes nshoes changed the title Fix console drag-and-drop uploads (closes #1930) Fix console drag-and-drop uploads Mar 6, 2025
e.dataTransfer.items.forEach(item => {
const file = item.getAsFile()
const reader = file.stream().getReader()
if (e.dataTransfer.items) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any ideas on what caused this to break?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From what I could tell, its that e.dataTransfer.items.forEach is the culprit. I don't think forEach is a method on items.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, makes sense! Thanks.

@joshk joshk linked an issue Mar 6, 2025 that may be closed by this pull request
@joshk joshk merged commit 34a985c into main Mar 6, 2025
2 checks passed
@joshk joshk deleted the fix-console-uploads branch March 6, 2025 20:21
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.

Drag-and-Drop files onto console no longer works
2 participants