mirror of
https://github.com/apache/struts.git
synced 2026-08-11 01:27:14 +00:00
WW-4391 FreemarkerResult uses response content encoding in first place
This commit is contained in:
@@ -343,7 +343,10 @@ public class FreemarkerResult extends StrutsResultSupport {
|
||||
contentType = "text/html";
|
||||
}
|
||||
|
||||
String encoding = template.getEncoding();
|
||||
String encoding = response.getCharacterEncoding();
|
||||
if(encoding == null) {
|
||||
encoding = template.getEncoding();
|
||||
}
|
||||
|
||||
if (encoding != null) {
|
||||
contentType = contentType + "; charset=" + encoding;
|
||||
|
||||
Reference in New Issue
Block a user