Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Implemented Plack::Util::load_psgi

  • Loading branch information...
commit 087e64135b6b71b6cdff004ab7ed0991aed8b98c 1 parent 1984615
@miyagawa authored
Showing with 1 addition and 5 deletions.
  1. +1 −5 lib/Perlbal/Plugin/PSGI.pm
View
6 lib/Perlbal/Plugin/PSGI.pm
@@ -63,11 +63,7 @@ sub handle_psgi_app_command {
my $mc = shift->parse(qr/^psgi_app\s*=\s*(\S+)$/, "usage: PSGI_APP=<path>");
my ($app_path) = $mc->args;
- my $handler = do $app_path;
- unless (defined $handler && ref $handler eq 'CODE') {
- return $mc->err("Failed to load $app_path: " . ($! || $@))
- }
-
+ my $handler = Plack::Util::load_psgi $app_path;
my $svcname;
unless ($svcname ||= $mc->{ctx}{last_created}) {
return $mc->err("No service name in context from CREATE SERVICE <name> or USE <service_name>");
Please sign in to comment.
Something went wrong with that request. Please try again.