From 816ecc393c141ae02590977f97bd0f8b28662bdb Mon Sep 17 00:00:00 2001 From: "Cathy J. Fitzpatrick" Date: Sat, 22 Jun 2013 00:14:25 -0500 Subject: [PATCH] Fix directory indexes --- .htaccess | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.htaccess b/.htaccess index 6d433912e..e3d43b984 100644 --- a/.htaccess +++ b/.htaccess @@ -32,7 +32,9 @@ RewriteRule ^battle-([a-z]+[0-9]{1,7})$ http%{ENV:P_SUFFIX}://pokemonshowdown.co # TODO: fix bug where you can't join lobby directly RewriteRule ^lobby/?$ / [R=301,L] -# roomid with a slash after it: remove the slash +# roomid with a slash after it: remove the slash, unless the roomid +# is also an actual directory +RewriteCond %{DOCUMENT_ROOT}/$1 !-d RewriteRule ^([A-Za-z0-9][A-Za-z0-9-]*)/$ /$1 [R=301,L] #RewriteCond %{ENV:P_SUFFIX} =s