diff options
-rw-r--r-- | lib/Plack/Client.pm | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Plack/Client.pm b/lib/Plack/Client.pm index 82630f8..d97f44c 100644 --- a/lib/Plack/Client.pm +++ b/lib/Plack/Client.pm @@ -5,6 +5,7 @@ use warnings; use HTTP::Message::PSGI; use HTTP::Request; use Plack::App::Proxy; +use Plack::Middleware::ContentLength; use Plack::Response; use Scalar::Util qw(blessed); @@ -42,6 +43,7 @@ sub request { if ($scheme eq 'psgi-local') { $req->uri->path('/') unless length $req->uri->path; $app = $self->app_for($req->uri->authority); + $app = Plack::Middleware::ContentLength->wrap($app); } elsif ($scheme eq 'http' || $scheme eq 'https') { my $uri = $req->uri->clone; |