Commits

Anonymous committed a13b744

Use constant of the content encoding header
Submitted by: L. Torunski

  • Participants
  • Parent commits be829f4

Comments (0)

Files changed (1)

File src/core/java/com/opensymphony/oscache/web/filter/ResponseContent.java

         // Don't add in the Last-Modified header in a fragment of a page
         if ((!fragment) && (lastModified != -1) && (response instanceof HttpServletResponse)) {
             ((HttpServletResponse) response).setDateHeader(CacheFilter.HEADER_LAST_MODIFIED, lastModified);
-        }
+        } // FIXME maybe remove header if it exists
 
         if (locale != null) {
             response.setLocale(locale);
 
         if (isContentGZiped()) {
             if (acceptsGZip) {
-                ((HttpServletResponse) response).addHeader("Content-Encoding", "gzip");
+                ((HttpServletResponse) response).addHeader(CacheFilter.HEADER_CONTENT_ENCODING, "gzip");
                 response.setContentLength(content.length);
                 out.write(content);
             } else {