[Catalyst-commits] r6278 - trunk/Catalyst-Runtime/lib/Catalyst/Engine

zarquon at dev.catalyst.perl.org zarquon at dev.catalyst.perl.org
Wed Apr 4 03:17:21 GMT 2007


Author: zarquon
Date: 2007-04-04 03:17:20 +0100 (Wed, 04 Apr 2007)
New Revision: 6278

Modified:
   trunk/Catalyst-Runtime/lib/Catalyst/Engine/CGI.pm
Log:
fixed final svk botch

Modified: trunk/Catalyst-Runtime/lib/Catalyst/Engine/CGI.pm
===================================================================
--- trunk/Catalyst-Runtime/lib/Catalyst/Engine/CGI.pm	2007-04-04 02:01:04 UTC (rev 6277)
+++ trunk/Catalyst-Runtime/lib/Catalyst/Engine/CGI.pm	2007-04-04 02:17:20 UTC (rev 6278)
@@ -135,10 +135,7 @@
         $port = $c->request->secure ? 443 : 80;
     }
 
-    # set the base URI
-    # base must end in a slash
-    $base_path .= '/' unless ( $base_path =~ /\/$/ );
-
+    # set the request URI
     my $path = $base_path . ( $ENV{PATH_INFO} || '' );
     $path =~ s{^/+}{};
     
@@ -161,12 +158,13 @@
 
     $c->request->uri( bless \$uri, $uri_class );
 
-    # sanitize the URI
-    $uri = $uri->canonical;
-    $c->request->uri($uri);
-    my $base = $uri->clone;
-    $base->path_query($base_path);
-    $c->request->base($base);
+    # set the base URI
+    # base must end in a slash
+    $base_path .= '/' unless $base_path =~ m{/$};
+    
+    my $base_uri = $scheme . '://' . $host . $base_path;
+
+    $c->request->base( bless \$base_uri, $uri_class );
 }
 
 =head2 $self->prepare_query_parameters($c)




More information about the Catalyst-commits mailing list