Skip to content

Commit

Permalink
Uses better class resolver logic
Browse files Browse the repository at this point in the history
  • Loading branch information
lukaszlenart committed Aug 26, 2017
1 parent ed7f9dd commit 2306f5f
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
import freemarker.cache.MultiTemplateLoader;
import freemarker.cache.TemplateLoader;
import freemarker.cache.WebappTemplateLoader;
import freemarker.core.TemplateClassResolver;
import freemarker.ext.jsp.TaglibFactory;
import freemarker.ext.servlet.HttpRequestHashModel;
import freemarker.ext.servlet.HttpRequestParametersHashModel;
Expand Down Expand Up @@ -344,6 +345,9 @@ protected Configuration createConfiguration(ServletContext servletContext) throw
configuration.setLocalizedLookup(false);
configuration.setWhitespaceStripping(true);

LOG.debug("Sets NewBuiltinClassResolver to TemplateClassResolver.SAFER_RESOLVER");
configuration.setNewBuiltinClassResolver(TemplateClassResolver.SAFER_RESOLVER);

return configuration;
}

Expand Down

0 comments on commit 2306f5f

Please sign in to comment.