summary refs log tree commit diff
diff options
context:
space:
mode:
authorfranck cuny <franck@lumberjaph.net>2011-07-11 10:40:39 +0200
committerfranck cuny <franck@lumberjaph.net>2011-07-26 13:20:00 +0200
commitcdf0c1f28306bf7f69ab4c9e05adade7d0b24edc (patch)
tree418717b7735eb0a2b416479fd957791f46420844
parentadd spore.userinfo (diff)
downloadnet-http-spore-cdf0c1f28306bf7f69ab4c9e05adade7d0b24edc.tar.gz
userinfo if available
Signed-off-by: franck cuny <franck@lumberjaph.net>
-rw-r--r--lib/Net/HTTP/Spore/Request.pm6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/Net/HTTP/Spore/Request.pm b/lib/Net/HTTP/Spore/Request.pm
index d65e0e9..3551e12 100644
--- a/lib/Net/HTTP/Spore/Request.pm
+++ b/lib/Net/HTTP/Spore/Request.pm
@@ -202,7 +202,11 @@ sub _uri_base {
 
     my $uri =
       ( $env->{'spore.url_scheme'} || "http" ) . "://"
-          .($env->{'spore.userinfo'} . '@'|| '')
+      . (
+        defined $env->{'spore.userinfo'}
+        ? $env->{'spore.userinfo'} . '@'
+        : ''
+      )
       . (
         $env->{HTTP_HOST}
           || (( $env->{SERVER_NAME} || "" ) . ":"