]> Sergey Matveev's repositories - public-inbox.git/commitdiff
httpd: (cleanup) use reference instead of *glob
authorEric Wong <e@80x24.org>
Mon, 8 Jul 2019 07:22:31 +0000 (07:22 +0000)
committerEric Wong <e@80x24.org>
Mon, 8 Jul 2019 07:29:26 +0000 (07:29 +0000)
*glob notation isn't always necessary, and there's
no need to disable 'once' warnings, this way.

lib/PublicInbox/HTTPD.pm

index b0bf94adf7dda314d3d4bb2d134874334d1d5b75..d10ec51c373e041640c572e7c90a0b274db38df6 100644 (file)
@@ -39,10 +39,7 @@ sub new {
                # The rest of our PSGI code is generic, relying
                # on "pull" model using "getline" to prevent
                # over-buffering.
-               'pi-httpd.async' => do {
-                       no warnings 'once';
-                       *pi_httpd_async
-               },
+               'pi-httpd.async' => \&pi_httpd_async
        );
        bless {
                app => $app,