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

Require Non-capturing catch #51

Merged
merged 1 commit into from
Dec 2, 2021
Merged

Require Non-capturing catch #51

merged 1 commit into from
Dec 2, 2021

Conversation

simPod
Copy link
Contributor

@simPod simPod commented Nov 26, 2021

https://github.com/slevomat/coding-standard#slevomatcodingstandardexceptionsdisallownoncapturingcatch

try {
    changeImportantData();
} catch (PermissionException) { // The intention is clear: exception details are irrelevant
    echo "You don't have permission to do this";
}

@simPod simPod merged commit 3e388b5 into master Dec 2, 2021
@simPod simPod deleted the non-capt-catch branch December 2, 2021 14:32
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.

None yet

2 participants