- Made :Path behave sanely at the root, hopefully
[catagits/Catalyst-Runtime.git] / lib / Catalyst / DispatchType / Path.pm
index ccff553..2cb950d 100644 (file)
@@ -64,6 +64,7 @@ sub register {
     foreach my $r ( @{ $attrs->{Path} || [] } ) {
         unless ($r) {
             $r = $action->namespace;
+            $r = '' if $r eq '/';
         }
         elsif ( $r !~ m!^/! ) {    # It's a relative path
             $r = $action->namespace . "/$r";