myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mat...@apache.org
Subject svn commit: r691382 - /myfaces/trinidad/branches/1.2.8.1-branch/trinidad-api/src/main/java/org/apache/myfaces/trinidad/webapp/ResourceServlet.java
Date Tue, 02 Sep 2008 21:00:07 GMT
Author: matzew
Date: Tue Sep  2 14:00:06 2008
New Revision: 691382

URL: http://svn.apache.org/viewvc?rev=691382&view=rev
Log:
TRINIDAD-1208 - DOCUMENT TYPE FOR JAVASCRIPT IS MISSING

Thanks to Tadashi Enomori for his patch

Modified:
    myfaces/trinidad/branches/1.2.8.1-branch/trinidad-api/src/main/java/org/apache/myfaces/trinidad/webapp/ResourceServlet.java

Modified: myfaces/trinidad/branches/1.2.8.1-branch/trinidad-api/src/main/java/org/apache/myfaces/trinidad/webapp/ResourceServlet.java
URL: http://svn.apache.org/viewvc/myfaces/trinidad/branches/1.2.8.1-branch/trinidad-api/src/main/java/org/apache/myfaces/trinidad/webapp/ResourceServlet.java?rev=691382&r1=691381&r2=691382&view=diff
==============================================================================
--- myfaces/trinidad/branches/1.2.8.1-branch/trinidad-api/src/main/java/org/apache/myfaces/trinidad/webapp/ResourceServlet.java
(original)
+++ myfaces/trinidad/branches/1.2.8.1-branch/trinidad-api/src/main/java/org/apache/myfaces/trinidad/webapp/ResourceServlet.java
Tue Sep  2 14:00:06 2008
@@ -439,7 +439,9 @@
       String resourcePath = url.getPath();
       if(resourcePath.endsWith(".css"))
         contentType = "text/css";
-      else
+      else if(resourcePath.endsWith(".js"))
+        contentType = "application/x-javascript";
+       else
         contentType = getServletContext().getMimeType(resourcePath);
     }
     response.setContentType(contentType);



Mime
View raw message