Joined February 2012
·
Posted to
Rails 3.2 error handling with exceptions_app
over 1 year
ago
This is a much better way to do this
config.exceptions_app = proc{|env|
ErrorsController.action(:render_error).call(env)
}
Achievements
98 Karma
0 Total ProTip Views
Honey Badger
Have at least one original Node.js-specific repo
Philanthropist
Truly improve developer quality of life by sharing at least 50 individual open source projects
Octopussy
Have a repo followed by a member of the GitHub team
Walrus
The walrus is no stranger to variety. Use at least 4 different languages throughout all your repos
Altruist
Increase developer well-being by sharing at least 20 open source projects
Forked
Have a project valued enough to be forked by someone else
Charity
Fork and commit to someone's open source project in need
Mongoose 3
Have at least three original repos where Ruby is the dominant language
Mongoose
Have at least one original repo where Ruby is the dominant language
Cub
Have at least one original jQuery or Prototype open source repo
For some more context: We have an app where with a
route which was raising a second exception to an obscure status code route.
I highly recommend anyone who needs to render errors this way either use controller exception catching or bypass the rails router all together.