Skip to content

Failed upload into a deleted folder throws an uncaught error #4318

Closed

Description

@AlexAndBear

Initial Checklist

  • I understand this is a bug report and questions should be posted in the Community Discussions
  • I searched issues and couldn’t find anything (or linked relevant results below)

Bug Description

Since #4207, a failed upload into a folder that no longer exists throws an uncaught "Resource not found" page error. The upload panel shows the failure correctly, but the file list refresh that #4207 now also runs for failed uploads isn't guarded.

Reproduction Steps

  1. Open a folder
  2. Delete that folder in another tab (or via WebDAV)
  3. Upload a file into the still open folder, then retry it

Expected Outcome

The upload panel shows the failure, without an uncaught error.

Actual Outcome

The upload fails (412), then a PROPFIND on the folder returns 404 and Resource not found is thrown as an uncaught page error, again on every retry. useFileUpload.ts refreshes on result.successful?.[0] || result.failed?.[0] and the refresh (getDrive / listFiles) has no error handling.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions