diff options
author | José Valim <jose.valim@gmail.com> | 2010-12-23 19:17:02 +0100 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-12-23 19:17:02 +0100 |
commit | 819b8cae40623d26ce3c050d482b490539a25b98 (patch) | |
tree | 44d62b397d7eac18be664f24b0b8aeff53535876 /actionpack/lib | |
parent | df3cfa6aaea326bb60b639524abbcc1f73854d1f (diff) | |
download | rails-819b8cae40623d26ce3c050d482b490539a25b98.tar.gz rails-819b8cae40623d26ce3c050d482b490539a25b98.tar.bz2 rails-819b8cae40623d26ce3c050d482b490539a25b98.zip |
Clean up callbacks should also be called on exceptions.
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_dispatch/middleware/reloader.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/actionpack/lib/action_dispatch/middleware/reloader.rb b/actionpack/lib/action_dispatch/middleware/reloader.rb index 7624a1871a..f6ab368ad8 100644 --- a/actionpack/lib/action_dispatch/middleware/reloader.rb +++ b/actionpack/lib/action_dispatch/middleware/reloader.rb @@ -68,6 +68,9 @@ module ActionDispatch response = @app.call(env) response[2].extend(CleanupOnClose) response + rescue Exception + _run_cleanup_callbacks + raise end end end |