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

Remove extra exception wrapper allocation #321

Merged
merged 1 commit into from
Oct 19, 2022
Merged

Commits on Sep 27, 2022

  1. Remove extra exception wrapper allocation

    ```ruby
    ActionDispatch::ExceptionWrapper.new(backtrace_cleaner, exception).exception
    ```
    
    The above code just returns the original exception object.  You can see
    [in
    Rails](https://github.com/rails/rails/blob/08ef43ed5e01b42b2aec847a0424515f537ed427/actionpack/lib/action_dispatch/middleware/exception_wrapper.rb#L44-L48)
    the exception is simply stored in an ivar and then returned with an
    attr_reader.  There shouldn't be any reason to construct this object
    tenderlove committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    2984e65 View commit details
    Browse the repository at this point in the history