Yuhi Ishikura
2013-06-02 1dcfd2e983489e3f6c318e1d30ae59c925349fbc
Fixed problem that PagesServlet couldn't provide index.htm and index.mkd.
1 files modified
7 ■■■■ changed files
src/main/java/com/gitblit/PagesServlet.java 7 ●●●● patch | view | raw | blame | history
src/main/java/com/gitblit/PagesServlet.java
@@ -149,8 +149,11 @@
                // find resource
                String[] files = { "index.html", "index.htm", "index.mkd" };
                for (String file : files) {
                    content = JGitUtils.getStringContent(r, tree, file, encodings)
                            .getBytes(Constants.ENCODING);
                    String stringContent = JGitUtils.getStringContent(r, tree, file, encodings);
                    if(stringContent == null){
                        continue;
                    }
                    content = stringContent.getBytes(Constants.ENCODING);
                    if (content != null) {
                        resource = file;
                        // assume text/html unless the servlet container