Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

wrapped long lines for nicer display in 80 column terminals

  • Loading branch information...
commit cec09ef8f9242b60b22cc5df8b41cf3acf195d22 1 parent 9fb9ea6
@milu71 milu71 authored
Showing with 7 additions and 3 deletions.
  1. +7 −3 PSGI.pod
View
10 PSGI.pod
@@ -471,7 +471,8 @@ L<IO::Handle>-like object.
open my $body, "<:via(SomePerlIO)", ...;
my $body = IO::File->new("/path/to/file");
- my $body = SomeClass->new(); # mock class that implements getline() and close()
+ # mock class that implements getline() and close()
+ my $body = SomeClass->new();
Servers B<SHOULD NOT> check the type or class of the body. Instead, they should
simply call C<getline> to iterate over the body, and
@@ -541,7 +542,8 @@ methods. Again, an example illustrates this best.
# immediately starts the response and stream the content
return sub {
my $responder = shift;
- my $writer = $responder->([ 200, [ 'Content-Type', 'application/json' ]]);
+ my $writer = $responder->(
+ [ 200, [ 'Content-Type', 'application/json' ]]);
wait_for_events(sub {
my $new_event = shift;
@@ -574,7 +576,9 @@ I<X-PSGI-Used> to any PSGI application.
# $app is a simple PSGI application
my $app = sub {
my $env = shift;
- return [ '200', [ 'Content-Type' => 'text/plain' ], [ "Hello World" ] ];
+ return [ '200',
+ [ 'Content-Type' => 'text/plain' ],
+ [ "Hello World" ] ];
};
# $xheader is a piece of middleware that wraps $app
Please sign in to comment.
Something went wrong with that request. Please try again.