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

Change the exception superclass to StandardError #85

Merged
merged 1 commit into from
Apr 29, 2015

Conversation

branliu0
Copy link
Contributor

Changed the superclass of MediaWiki::Exception from ::Exception to ::StandardError.

It's best practice in Ruby to rescue StandardError instead of Exception. Exceptions that are not StandardErrors are reserved for things like Interrupts, out of memory errors, and so on. Normal Ruby code is supposed to use StandardErrors.

Changed the superclass of MediaWiki::Exception from ::Exception to ::StandardError.

It's best practice in Ruby to rescue StandardError instead of Exception. Exceptions that are not StandardErrors are reserved for things like Interrupts, out of memory errors, and so on. Normal Ruby code is supposed to use StandardErrors.
jpatokal added a commit that referenced this pull request Apr 29, 2015
Change the exception superclass to StandardError
@jpatokal jpatokal merged commit 05935e9 into jpatokal:master Apr 29, 2015
@jpatokal
Copy link
Owner

Merged, thank you!

@branliu0 branliu0 deleted the standarderror branch April 29, 2015 10:17
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