diff --git a/core/modules/commands/server.js b/core/modules/commands/server.js index fcb097f1b..65790fc10 100644 --- a/core/modules/commands/server.js +++ b/core/modules/commands/server.js @@ -58,7 +58,7 @@ SimpleServer.prototype.findMatchingRoute = function(request,state) { match; if(pathprefix) { if(pathname.substr(0,pathprefix.length) === pathprefix) { - pathname = pathname.substr(pathprefix.length); + pathname = pathname.substr(pathprefix.length) || "/"; match = potentialRoute.path.exec(pathname); } else { match = false;