Skip to content

[FIX] App crashes when downloads come from WebDAV and the server is not available#21985

Merged
sampaiodiego merged 2 commits intodevelopfrom
fix/webdav-fallback
May 20, 2021
Merged

[FIX] App crashes when downloads come from WebDAV and the server is not available#21985
sampaiodiego merged 2 commits intodevelopfrom
fix/webdav-fallback

Conversation

@KevLehman
Copy link
Member

…ilable

Proposed changes (including videos or screenshots)

Issue(s)

Steps to test or reproduce

Further comments

this.store.getReadStream(file._id, file)
.on('error', () => {
console.error('An error ocurred when fetching the file');
res.writeHead(400);
Copy link
Member Author

Choose a reason for hiding this comment

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

What can be handled better by the FE? A 500 with a message? The current 400 + log? A 404?

Copy link
Member

Choose a reason for hiding this comment

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

I'd say we should reply either 503 or 500..

Copy link
Member Author

Choose a reason for hiding this comment

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

A 503 should work :)

@KevLehman KevLehman requested a review from a team May 7, 2021 14:39
@sampaiodiego sampaiodiego changed the title [Fix] App crashes when downloads come from webdav and the server is not available [FIX] App crashes when downloads come from WebDAV and the server is not available May 20, 2021
@sampaiodiego sampaiodiego merged commit 44d1df1 into develop May 20, 2021
@sampaiodiego sampaiodiego deleted the fix/webdav-fallback branch May 20, 2021 19:08
@sampaiodiego sampaiodiego mentioned this pull request May 28, 2021
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

Comments