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: keep previous exception when wrapping dav exceptions #46685

Merged
merged 1 commit into from
Jul 25, 2024

Conversation

icewind1991
Copy link
Member

No need to throw away valuable context

@icewind1991 icewind1991 added the 3. to review Waiting for reviews label Jul 22, 2024
@icewind1991 icewind1991 added this to the Nextcloud 30 milestone Jul 22, 2024
@icewind1991 icewind1991 requested review from a team, ArtificialOwl, yemkareems and sorbaugh and removed request for a team July 22, 2024 13:42
} catch (InvalidPathException $ex) {
throw new InvalidPath($ex->getMessage());
throw new InvalidPath($ex->getMessage(), $ex->getCode(), $ex);

Check failure

Code scanning / Psalm

InvalidArgument Error

Argument 2 of OCA\DAV\Connector\Sabre\Exception\InvalidPath::__construct expects bool, but int provided
} catch (ForbiddenException $e) {
throw new \Sabre\DAV\Exception\Forbidden();
throw new \Sabre\DAV\Exception\Forbidden($ex->getMessage(), $ex->getRetry(), $ex);

Check failure

Code scanning / Psalm

UndefinedVariable Error

Cannot find referenced variable $ex
} catch (ForbiddenException $e) {
throw new \Sabre\DAV\Exception\Forbidden();
throw new \Sabre\DAV\Exception\Forbidden($ex->getMessage(), $ex->getRetry(), $ex);

Check failure

Code scanning / Psalm

UndefinedVariable Error

Cannot find referenced variable $ex
} catch (ForbiddenException $e) {
throw new \Sabre\DAV\Exception\Forbidden();
throw new \Sabre\DAV\Exception\Forbidden($ex->getMessage(), $ex->getRetry(), $ex);

Check failure

Code scanning / Psalm

UndefinedVariable Error

Cannot find referenced variable $ex
Signed-off-by: Robin Appelman <robin@icewind.nl>
@icewind1991 icewind1991 force-pushed the sabre-directory-exception-previous branch from d16ad2a to d5a2a4a Compare July 23, 2024 12:23
@icewind1991 icewind1991 merged commit 6953be7 into master Jul 25, 2024
167 checks passed
@icewind1991 icewind1991 deleted the sabre-directory-exception-previous branch July 25, 2024 12:39
@blizzz blizzz mentioned this pull request Jul 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants