summaryrefslogtreecommitdiffstats
path: root/src/main/java/com/gitblit/servlet/RawServlet.java
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2015-11-23 13:48:25 -0500
committerJames Moger <james.moger@gitblit.com>2015-11-23 13:48:25 -0500
commit66e081e2dcbca1524003a728d11e7f5ccbdb7bf1 (patch)
tree879e77be0efe0440ccab5243e4ff0191bf44a21d /src/main/java/com/gitblit/servlet/RawServlet.java
parent3cbfebba9a8c5ca343aba2511d3a7874b0c650ec (diff)
downloadgitblit-66e081e2dcbca1524003a728d11e7f5ccbdb7bf1.tar.gz
gitblit-66e081e2dcbca1524003a728d11e7f5ccbdb7bf1.zip
Raw servlet now assumes text/plain for dot files
Diffstat (limited to 'src/main/java/com/gitblit/servlet/RawServlet.java')
-rw-r--r--src/main/java/com/gitblit/servlet/RawServlet.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/gitblit/servlet/RawServlet.java b/src/main/java/com/gitblit/servlet/RawServlet.java
index e11bc505..81793bc7 100644
--- a/src/main/java/com/gitblit/servlet/RawServlet.java
+++ b/src/main/java/com/gitblit/servlet/RawServlet.java
@@ -233,7 +233,7 @@ public class RawServlet extends HttpServlet {
try {
String ext = StringUtils.getFileExtension(file).toLowerCase();
- String contentType = quickContentTypes.get(ext);
+ String contentType = file.charAt(0) == '.' ? "text/plain" : quickContentTypes.get(ext);
if (contentType == null) {
List<String> exts = runtimeManager.getSettings().getStrings(Keys.web.prettyPrintExtensions);