- Fixed warning
Matt S Trout [Wed, 12 Oct 2005 19:30:06 +0000 (19:30 +0000)]
lib/Catalyst/Dispatcher.pm

index 89de3ca..18ddc4b 100644 (file)
@@ -137,9 +137,9 @@ sub forward {
     my $command_copy = $command;
 
     unless ( $command_copy =~ s/^\/// ) {
-        $command_copy =
-          Catalyst::Utils::class2prefix( $caller, $c->config->{case_sensitive} )
-          . "/${command}";
+        my $namespace =
+          Catalyst::Utils::class2prefix( $caller, $c->config->{case_sensitive} ) || '';
+        $command_copy = "${namespace}/${command}";
     }
 
     unless ( $command_copy =~ /\// ) {