Skip to content

Rack::BodyProxy with Rack::ContentLength middleware #734

@martinotten

Description

@martinotten

I ran into this issue using the Rack::ContentLength middleware with Rails 4.1.5. The middleware checks body.respond_to?(:to_ary) before calculating the Content-Length header. This fails if the body is a Rack::BodyProxy. The line has been added in 5b251a9 to fix #419 . Is there another solution for 419 or should the middleware be changed? It seems there is also no spec for this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions